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

Ivan Kelly commented on BOOKKEEPER-79:
--------------------------------------

The above code will deadlock on mutexes. There's a number of issues, one being 
that we try to handle the messages in the async io thread.

I've made an attempt to sort this out, and it just gets ugly. Also, I think we 
should block stopDelivery from returning until we have stopped all reads, 
otherwise callbacks may trigger when we don't expect them. Trying this with 
some locks leads to deadlocks.

https://github.com/ivankelly/bookkeeper/tree/BOOKKEEPER-79

We can discuss this tomorrow morning.
                
> randomly startDelivery/stopDelivery will core dump in c++ hedwig client
> -----------------------------------------------------------------------
>
>                 Key: BOOKKEEPER-79
>                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-79
>             Project: Bookkeeper
>          Issue Type: Bug
>          Components: hedwig-client
>    Affects Versions: 4.0.0
>            Reporter: Sijie Guo
>            Assignee: Sijie Guo
>             Fix For: 4.0.0
>
>         Attachments: BOOKKEEPER-79.patch_v2, bookkeeper-79.patch, 
> pubsubtest.cpp
>
>
> in our test program, we tried to startDelivery/stopDelivery different 
> subscriptions randomly. And it core dump.

--
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

        

Reply via email to