Flink中因java的泛型擦除导致的报错及解决

【报错】

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.

【解决】

好,我接受他的建议

再次运行

数据正常!

相关推荐
权泽谦8 分钟前
从零搭建一个 PHP 登录注册系统(含完整源码)
android·开发语言·php
PieroPc14 分钟前
用python Streamlit 做个RapidOCR 文本识别系统
开发语言·python·ocr
暖木生晖24 分钟前
Javascript函数之匿名函数以及立即执行函数的使用方法?
开发语言·javascript·ecmascript
say_fall32 分钟前
C语言容易被忽略的易错点(2)
c语言·开发语言
光影少年33 分钟前
React Native第六章
javascript·react native·react.js
晓得迷路了37 分钟前
栗子前端技术周刊第 105 期 - npm 安全性加强、Storybook 10、htmx 4.0 Alpha 1...
前端·javascript·npm
syker43 分钟前
NEWBASIC 2.06.7 API 帮助与用户使用手册
开发语言·人工智能·机器学习·自动化
Js_cold43 分钟前
Verilog运算符
开发语言·fpga开发·verilog
努力还债的学术吗喽1 小时前
【项目】pyqt5基于python的照片整蛊项目
开发语言·python·qt