pnowojski commented on a change in pull request #10446: [FLINK-15076][task] Fix 
SourceStreamTask cancellation
URL: https://github.com/apache/flink/pull/10446#discussion_r354495322
 
 

 ##########
 File path: 
flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/SourceStreamTask.java
 ##########
 @@ -131,8 +131,13 @@ protected void 
processInput(MailboxDefaultAction.Controller controller) throws E
 
        @Override
        protected void cancelTask() {
-               if (headOperator != null) {
-                       headOperator.cancel();
+               try {
+                       if (headOperator != null) {
+                               headOperator.cancel();
+                       }
+               }
+               finally {
+                       sourceThread.interrupt();
 
 Review comment:
   Could elaborate/rephrase what do you mean?

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to