You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/05/18 11:58:57 UTC

[GitHub] [flink] aljoscha commented on a change in pull request #12189: [FLINK-17376][API/DataStream]Deprecated methods and related code updated

aljoscha commented on a change in pull request #12189:
URL: https://github.com/apache/flink/pull/12189#discussion_r426572441



##########
File path: flink-connectors/flink-connector-filesystem/src/main/java/org/apache/flink/streaming/connectors/fs/bucketing/BucketingSink.java
##########
@@ -388,7 +389,7 @@ public void initializeState(FunctionInitializationContext context) throws Except
 		}
 
 		OperatorStateStore stateStore = context.getOperatorStateStore();
-		restoredBucketStates = stateStore.getSerializableListState("bucket-states");
+		this.restoredBucketStates = stateStore.getListState(new ListStateDescriptor("bucket-states", State.class));

Review comment:
       This will not actually work because `getListState(..., State.class)` should be created a `GenericTypeInfo`, which is incompatible with the `JavaSerializer` used before internally here.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org