但是在执行上面的代码时,出现如下所示的异常信息,意思是Person不能作为key: Exception in thread "main" org.apache.flink.api.common.InvalidProgramException: This type (GenericType<com.xueai8.ch03.TransformerKeyBy2.Person>) cannot be used as key. at org.apache.flink.api.common.operators.Keys$Express...
使用Flink keyBy函数时,参数为POJO对象报错 org.apache.flink.api.common.InvalidProgramException: This type XXX cannot be used as key 原因 POJO需要满足: class必须是public的 必须有public无参构造函数 属性名不能为is开头
记录一次flink报错 在本地测试一个flink程序的时候报了一个异常:org.apache.flink.api.common.InvalidProgramException: This type (GenericType<com.bart.flink.datasource.WordWithCount>) cannot be used as key 观察异常堆栈打印定位到代码中的keyBy这里,报错的代码如下: KeyedStream<WordWithCount, Tuple> word =...
flink 执行keyBy操作出现异常情况: Exception in thread "main" org.apache.flink.api.common.InvalidProgramException: This type (GenericType<com.hmh.entity.SensorEntity>) cannot be used as key. at org.apache.flink.api.common.operators.Keys$ExpressionKeys.<init>(Keys.java:330) at org.apache.flink....
private final KeySelector<T, KEY> keySelector; /** The type of the key by which the stream is partitioned. */ private final TypeInformation<KEY> keyType; /** * Creates a new {@link KeyedStream} using the given {@link KeySelector} ...
21.cannot be cast to com.google.protobuf.Message Caused by: java.lang.ClassCastException: org.apache.hadoop.yarn.proto.YarnServiceProtos$RegisterApplicationMasterRequestProto cannot be cast to com.google.protobuf.Message at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java...
* The key extractor could return the word as * a key to group all Word objects by the String they contain. * * The code would look like this * * public String getKey(Word w) { * return w.word; * } * * * @param value...
sum with the given column,in my mapFunction,I convert json to case class,but the result stream don't get compiler in keyBy function,got error Exception in thread "main" org.apache.flink.api.common.InvalidProgramException: This type (GenericType<java.lang.Object>) cannot be used as key.....
Flink CDC谁知道这是啥错吗?从页面上传jar包以后提交就报错?Caused by: org.apache.flink.api.common.InvalidProgramException: The LocalStreamEnvironment cannot be used when submitting a program through a client, or running in a TestEnvironment context. ...
org.apache.flink.api.common.InvalidProgramException:Thistype(GenericType<Test>)cannot be usedaskey ...