incubator-s4-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "kishore gopalakrishna (Commented) (JIRA)" <>
Subject [jira] [Commented] (S4-3) Sometimes one process node owns 2 tasks
Date Thu, 13 Oct 2011 21:01:12 GMT


kishore gopalakrishna commented on S4-3:

Agree with Flavio, instead of exiting we should think of solution;

Closing the session might be difficult to implement, checking if pNode exists after exception
seems to be sufficient. How ever just this check may not be sufficient, additional check is
necessary to see if the EphemeralOwner of the Node is same as the sessionId.  Otherwise, some
other node might have acquired that task and this node thinks it acquired it. 

So along with pNode exists check if it was created by created by same process either by checking
ephemeralOwner or reading contents of the znode.

> Sometimes one process node owns 2 tasks
> ---------------------------------------
>                 Key: S4-3
>                 URL:
>             Project: Apache S4
>          Issue Type: Bug
>            Reporter: Gavin Li
>            Assignee: Gavin Li
>         Attachments: s4_loscon_fix
> When using S4, we found sometimes it ends up with one process node owns 2 tasks. I did
some investigation, it seems that the handling of ConnectionLossException when creating the
ephemeral node is problematic. Sometimes when the response from zookeeper server times out,
zookeeper.create() will fail with ConnectionLossException while the creation request might
already be sent to server(see
line 830). From our logs this is the case we ran into.
> Maybe we should handle it in the way that HBase is handling it (,
just simply exit the process when got that exception to let the whole process restart.
> To be more clear, what happened was: a process node called zookeeper.create() to acquire
a task, the request was successfully sent to zookeeper server, but the zookeeper IO loop timed
out before the response came. So the zookeeper.create() failed with ConnectionLossException.
Then the process node ignored this exception and tried to acquire another task. Then it got
2 tasks.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message