Hi everyone, -- I'm working to upgrade my environment to Flink v.1.6.0 and I'm facing an issue. We're using TwoInputStreamOperatorTestHarness in our tests and after upgrade to 1.6.0 my project compilation fails with "cannot find symbol TwoInputStreamOperatorTestHarness". I've reproduced the problem on a clean environment with a template project created from maven archetype. If you include additional dependency of TwoInputStreamOperatorTestHarness it's not able to find it. Here is the sample program: ``` package com.five9.streaming; import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment; import org.apache.flink.streaming.util.TwoInputStreamOperatorTestHarness; public class StreamingJob { public static void main(String[] args) throws Exception { final StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment(); env.execute("Example"); } } ``` Maven `mvn clean package` fails with: Caused by: org.apache.maven.plugin.compiler.CompilationFailureException: Compilation failure /home/dminaev/projects/belka/src/main/java/com/five9/streaming/StreamingJob.java:[22,39] cannot find symbol symbol: class TwoInputStreamOperatorTestHarness location: package org.apache.flink.streaming.util I looked up in the ".m2" local cache and found out that v.1.4.0 contains "flink-streaming-java_2.11-1.4.0-tests.jar" which has TwoInputStreamOperatorTestHarness.class, however, there is no "flink-streaming-java_2.11-1.6.0-tests.jar" included in v.1.6.0 Am I missing something and this class is deprecated or moved somewhere? I cannot find any reference to that. Please let me know if you have any ideas on how to fix the issue? Kind regards, Dmitry -- |
Hi Dmitry, I confirmed that this class is included in the source code of Flink-1.6 [1]. I just downloaded the source code of Flink-1.6 [2], and then run mvn package -DskipTests directly in the flink-streaming-java directory. The package is successful and decompiled to see that this class exists. Please confirm again. Thanks, vino. Dmitry Minaev <[hidden email]> 于2018年8月12日周日 下午1:16写道:
|
Thank you for your help, vino. I've resolved it, the issue was on my side, I forgot to include flink-streaming-java_2.11 with a type test-jar like the following: <dependency> <groupId>org.apache.flink</groupId> <artifactId>flink-streaming-java_${scala.binary.version}</artifactId> <version>${flink.version}</version> <type>test-jar</type> </dependency> ``` Once I included it, the issue got resolved. Thank you, Dmitry On Sat, Aug 11, 2018 at 11:08 PM vino yang <[hidden email]> wrote:
-- |
OK, it sounds great. Dmitry Minaev <[hidden email]> 于2018年8月14日周二 上午7:28写道:
|
Free forum by Nabble | Edit this page |