简体   繁体   English

在Scala中初始化Apache Beam测试管道失败

[英]Initializing Apache Beam Test Pipeline in Scala fails

When I try to run a test pipeline it raise an error 当我尝试运行测试管道时,会引发错误

here is the source code to create the test pipeline: 这是创建测试管道的源代码:

val p: TestPipeline = TestPipeline.create()

and here is the error : 这是错误:

java.lang.IllegalStateException: Is your TestPipeline declaration missing a @Rule annotation? java.lang.IllegalStateException:您的TestPipeline声明是否缺少@Rule注释? Usage: @Rule public final transient TestPipeline pipeline = TestPipeline.create(); 用法:@Rule公共最终瞬态TestPipeline管道= TestPipeline.create();

我已经通过以下代码解决了这个问题:

val p: TestPipeline = TestPipeline.create().enableAbandonedNodeEnforcement(false)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM