lindong28 commented on code in PR #20454:
URL: https://github.com/apache/flink/pull/20454#discussion_r941438963


##########
flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/RegularOperatorChain.java:
##########
@@ -198,7 +211,25 @@ public void snapshotState(
                                 storage));
             }
         }
-        sendAcknowledgeCheckpointEvent(checkpointMetaData.getCheckpointId());
+    }
+
+    private OperatorStateBackend getOperatorStateBackend(StreamOperator<?> 
operator) {
+        OperatorStateBackend backend = null;
+        if (operator instanceof AbstractStreamOperator) {
+            backend = ((AbstractStreamOperator<?>) 
operator).getOperatorStateBackend();
+        } else if (operator instanceof AbstractStreamOperatorV2) {
+            backend = ((AbstractStreamOperatorV2<?>) 
operator).getOperatorStateBackend();
+        }
+
+        if (backend == null) {

Review Comment:
   It seems more readable to use `else {...}` 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.

To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org

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

Reply via email to