You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@bookkeeper.apache.org by "Ivan Kelly (Updated) (JIRA)" <ji...@apache.org> on 2011/11/30 12:43:40 UTC
[jira] [Updated] (BOOKKEEPER-54) race condition of
messageHandler@SubscribeResponseHandler
[ https://issues.apache.org/jira/browse/BOOKKEEPER-54?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ivan Kelly updated BOOKKEEPER-54:
---------------------------------
Fix Version/s: (was: 4.0.0)
> race condition of messageHandler@SubscribeResponseHandler
> ---------------------------------------------------------
>
> Key: BOOKKEEPER-54
> URL: https://issues.apache.org/jira/browse/BOOKKEEPER-54
> Project: Bookkeeper
> Issue Type: Bug
> Components: hedwig-client
> Affects Versions: 4.0.0
> Reporter: xulei
>
> 1. As we know, when stopDelivery, the messageHandler will be set to null.
> 2. We also know that in SubscribeReconnectCallback.operationFinished(), we will check if the messageHandler is null, if messageHandler is not null, we will startDelivery.
> Both the reconnect thread and the main thread will race the messageHandler. For example,
> the reconnect handler checked that messageHandler is not null, and will startDelivery, then main thread exec stopDelivery, set messageHandler to null, and then reconnect thread exec startDelivery, set messageHandler back again. so although the client app stopDelivery, it still can receive message.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira