本文主要是介绍Flink中因java的泛型擦除导致的报错及解决,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
【报错】
Exception in thread "main" org.apache.flink.api.common.functions.InvalidTypesException: The return type of function 'Custom Source' 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.
【解决】
好,我接受他的建议
再次运行
数据正常!
这篇关于Flink中因java的泛型擦除导致的报错及解决的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!