You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@tez.apache.org by "Jeff Zhang (JIRA)" <ji...@apache.org> on 2015/06/12 02:09:02 UTC

[jira] [Comment Edited] (TEZ-2548) TezClient submitDAG can hang if the AM is in the process of shutting down

    [ https://issues.apache.org/jira/browse/TEZ-2548?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14582712#comment-14582712 ] 

Jeff Zhang edited comment on TEZ-2548 at 6/12/15 12:08 AM:
-----------------------------------------------------------

[~hitesh] Should set sessionStopped before DAGAppMaster#stop is invoked rather than inside DAGAppMaster#serviceStop ? or synchronized part of DAGAppMaster#serviceStop (move sessionStopped set out of synchronized block just as submitDAGToAppMaster does) 
I think the following cause may still cause the hang.
# serviceStop has not been triggered. 
# Thread-1 go to submitDAGToAppMaster and check sessionStopped as false, ready for synchronized block
# Switch to Thread-2,  Thread-2 start the synchronized block of serviceStop and hang
# Thread-1 hang in the synchronized block of submitDAGToAppMaster due to the hang in serviceStop


was (Author: zjffdu):
[~hitesh] Should set sessionStopped before DAGAppMaster#stop is invoked rather than inside DAGAppMaster#serviceStop ?
I think the following cause may still cause the hang.
# serviceStop has not been triggered. 
# Thread-1 go to submitDAGToAppMaster and check sessionStopped as false, ready for synchronized block
# Switch to Thread-2,  Thread-2 start the synchronized block of serviceStop and hang
# Thread-1 hang in the synchronized block of submitDAGToAppMaster due to the hang in serviceStop

> TezClient submitDAG can hang if the AM is in the process of shutting down
> -------------------------------------------------------------------------
>
>                 Key: TEZ-2548
>                 URL: https://issues.apache.org/jira/browse/TEZ-2548
>             Project: Apache Tez
>          Issue Type: Bug
>            Reporter: Hitesh Shah
>            Assignee: Hitesh Shah
>         Attachments: TEZ-2548.1.patch, TEZ-2548.2.patch, TEZ-2548.3.patch
>
>
> submitDAG and serviceStop are both synchronized causing submitDAG to be locked out during the shutdown process. 
> Seen by [~gopalv]



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)