我想在Row不知道其编号的情况下创建一个包含多个参数的参数.我在Scala中写了这样的东西:
def customRow(balance: Int,
globalGrade: Int,
indicators: Double*): Row = {
Row(
balance,
globalGrade,
indicators:_*
)
}
Run Code Online (Sandbox Code Playgroud)
在Spark GitHub上,该Row对象似乎接受了:_*考虑其apply方法的符号:
def apply(values: Any*): Row = new GenericRow(values.toArray)
Run Code Online (Sandbox Code Playgroud)
但是在编译时,似乎不允许这样做:
Error:(212, 19) no ': _*' annotation allowed here
(such annotations are only allowed in arguments to *-parameters)
indicators:_*
Run Code Online (Sandbox Code Playgroud)
我错过了什么?
我在 Windows 10 上安装了 Zeppelin 0.8.0。当我在带有 spark 解释器的笔记本中编写时,正确的代码工作正常,显示输出,但在出现错误时不显示堆栈跟踪。就像 in 是用白色写的,但实际上 ^ 之间的行是空的。
编辑: REPL 输出似乎已启用(带有解释器选项zeppelin.spark.printREPLOutput),因为我收到了错误输出。但这就像在打印之前清空了堆栈跟踪,导致只^显示指针。
我在 docker 容器中运行了 celery,我想检查该选项是否CELERY_TASK_RESULT_EXPIRES = '3600'已应用。
我尝试使用celery inspect confandcelery inspect stats但命令永远不会结束。除此之外,芹菜运行良好并发挥其作用。