Zakelly commented on code in PR #23987:
URL: https://github.com/apache/flink/pull/23987#discussion_r1438117996
##########
flink-streaming-java/src/main/java/org/apache/flink/streaming/api/environment/StreamExecutionEnvironment.java:
##########
@@ -1040,8 +1041,9 @@ public void configure(ReadableConfig configuration,
ClassLoader classLoader) {
configuration
.getOptional(StateChangelogOptions.ENABLE_STATE_CHANGE_LOG)
.ifPresent(this::enableChangelogStateBackend);
- Optional.ofNullable(loadStateBackend(configuration, classLoader))
- .ifPresent(this::setStateBackend);
+ configuration
+ .getOptional(StateBackendOptions.STATE_BACKEND)
+ .ifPresent(conf ->
setStateBackend(loadStateBackend(configuration, classLoader)));
Review Comment:
I'm not sure if it is right to setStateBackend here when user does not
explicitly config one. IIUC, the one set here will be the `fromApplication` in
`StreamTask.createStateBackend`, which overrides the cluster configuration.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]