在写Flink流式代码的时候,本地idea编译遇到了下面的问题
Exception in thread "main" org.apache.flink.api.common.functions.InvalidTypesException: The return type of function 'main(FlinkKafkaToMysql.java:56)' 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:479)
at org.apache.flink.streaming.api.datastream.DataStream.addSink(DataStream.java:1236)
at com.flink.example.FlinkKafkaToMysql.main(FlinkKafkaToMysql.java:63)
Caused by: org.apache.flink.api.common.functions.InvalidTypesException: The generic type parameters of 'List' are missing. In many cases lambda methods don't provid