Details
-
Bug
-
Status: Closed
-
Blocker
-
Resolution: Fixed
-
1.10.0
-
None
Description
2019-11-14 19:34:55,185 ERROR org.apache.flink.client.cli.CliFrontend - Error while running the command. org.apache.flink.client.program.ProgramInvocationException: The main method caused an error: The return type of function 'main(DataStreamAllroundTestProgram.java:182)' could not be determined automatically, due to type erasure. You can give type information hints by using the returns(...) method on the result of the transformation call, or by letting your function implement the 'ResultTypeQueryable' interface. at org.apache.flink.client.program.PackagedProgram.callMainMethod(PackagedProgram.java:336) at org.apache.flink.client.program.PackagedProgram.invokeInteractiveModeForExecution(PackagedProgram.java:206) at org.apache.flink.client.ClientUtils.executeProgram(ClientUtils.java:173) at org.apache.flink.client.cli.CliFrontend.executeProgram(CliFrontend.java:747) at org.apache.flink.client.cli.CliFrontend.runProgram(CliFrontend.java:282) at org.apache.flink.client.cli.CliFrontend.run(CliFrontend.java:219) at org.apache.flink.client.cli.CliFrontend.parseParameters(CliFrontend.java:1011) at org.apache.flink.client.cli.CliFrontend.lambda$main$10(CliFrontend.java:1084) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:422) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1836) at org.apache.flink.runtime.security.HadoopSecurityContext.runSecured(HadoopSecurityContext.java:41) at org.apache.flink.client.cli.CliFrontend.main(CliFrontend.java:1084) Caused by: org.apache.flink.api.common.functions.InvalidTypesException: The return type of function 'main(DataStreamAllroundTestProgram.java:182)' could not be determined automatically, due to type erasure. You can give type information hints by using the returns(...) method on the result of the transformation call, or by letting your function implement the 'ResultTypeQueryable' interface. at org.apache.flink.api.dag.Transformation.getOutputType(Transformation.java:412) at org.apache.flink.streaming.api.datastream.DataStream.addSink(DataStream.java:1296) at org.apache.flink.streaming.tests.DataStreamAllroundTestProgram.main(DataStreamAllroundTestProgram.java:185) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.flink.client.program.PackagedProgram.callMainMethod(PackagedProgram.java:322) ... 12 more Caused by: org.apache.flink.api.common.functions.InvalidTypesException: Input mismatch: Generic type 'org.apache.flink.streaming.tests.Event' or a subclass of it expected but was 'org.apache.flink.streaming.tests.Event'. at org.apache.flink.api.java.typeutils.TypeExtractor.validateInputType(TypeExtractor.java:1298) at org.apache.flink.api.java.typeutils.TypeExtractor.getUnaryOperatorReturnType(TypeExtractor.java:585) at org.apache.flink.api.java.typeutils.TypeExtractor.getFlatMapReturnTypes(TypeExtractor.java:196) at org.apache.flink.streaming.api.datastream.DataStream.flatMap(DataStream.java:634) at org.apache.flink.streaming.tests.DataStreamAllroundTestProgram.main(DataStreamAllroundTestProgram.java:182) ... 17 more Caused by: org.apache.flink.api.common.functions.InvalidTypesException: Generic type 'org.apache.flink.streaming.tests.Event' or a subclass of it expected but was 'org.apache.flink.streaming.tests.Event'. at org.apache.flink.api.java.typeutils.TypeExtractor.validateInfo(TypeExtractor.java:1481) at org.apache.flink.api.java.typeutils.TypeExtractor.validateInfo(TypeExtractor.java:1491) at org.apache.flink.api.java.typeutils.TypeExtractor.validateInputType(TypeExtractor.java:1295) ... 21 more
This happens in multiple nightlies and jepsen runs. Example
https://api.travis-ci.org/v3/job/611848582/log.txt