You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by ffbin <gi...@git.apache.org> on 2015/08/15 09:06:55 UTC

[GitHub] flink pull request: [FLINK-2526]Add try-catch for task when it sto...

GitHub user ffbin opened a pull request:

    https://github.com/apache/flink/pull/1020

    [FLINK-2526]Add try-catch for task when it stop running

    inputProcessor cleanup() may throw IOException.If do not catch it, the next line outputHandler .flushOutputs() will not work and cause output data loss.So i think add some try-catch is necessary.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/ffbin/flink FLINK-2526

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/1020.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1020
    
----
commit f846f56198c921f9285bce4fb25392d9d6e2a827
Author: ffbin <86...@qq.com>
Date:   2015-08-15T06:40:16Z

    [FLINK-2526]Add catch{} for task when it stop running

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-2526]Add try-catch for task when it sto...

Posted by StephanEwen <gi...@git.apache.org>.
Github user StephanEwen commented on the pull request:

    https://github.com/apache/flink/pull/1020#issuecomment-131390701
  
    The pull request #1017 actually fixes this as well, together with a lot of other things (similar problems are in many places).
    
    Can you have a look at #1017 and see if that would solve your concern?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-2526]Add try-catch for task when it sto...

Posted by ffbin <gi...@git.apache.org>.
Github user ffbin closed the pull request at:

    https://github.com/apache/flink/pull/1020


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-2526]Add try-catch for task when it sto...

Posted by zentol <gi...@git.apache.org>.
Github user zentol commented on a diff in the pull request:

    https://github.com/apache/flink/pull/1020#discussion_r37134398
  
    --- Diff: flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/runtime/tasks/OneInputStreamTask.java ---
    @@ -100,9 +100,27 @@ public void invoke() throws Exception {
     			this.isRunning = false;
     			// Cleanup
     			inputProcessor.clearBuffers();
    -			inputProcessor.cleanup();
    -			outputHandler.flushOutputs();
    -			clearBuffers();
    +
    +			try {
    +				inputProcessor.cleanup();
    +			}
    +			catch (Exception e) {
    +				LOG.warn("Clean up input processor failed.");
    --- End diff --
    
    the exception message shouldn't be discarded.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-2526]Add try-catch for task when it sto...

Posted by ffbin <gi...@git.apache.org>.
Github user ffbin commented on the pull request:

    https://github.com/apache/flink/pull/1020#issuecomment-131495368
  
    @StephanEwen  Thanks. I think you pull request has fixes this.I will close my pull request and view your code.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-2526]Add try-catch for task when it sto...

Posted by ffbin <gi...@git.apache.org>.
Github user ffbin commented on the pull request:

    https://github.com/apache/flink/pull/1020#issuecomment-131314931
  
    @zentol Hello! Thank you for your suggestion.I have add exception message in log.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---