Re: how to safely delete a cms::MessageListener object

2015-01-16 Thread Steve Rice
Awesome. Thanks, Tim. Steve Rice -- View this message in context: http://activemq.2283324.n4.nabble.com/how-to-safely-delete-a-cms-MessageListener-object-tp4689939p4690062.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: how to safely delete a cms::MessageListener object

2015-01-16 Thread Steve Rice
? Steve Rice -- View this message in context: http://activemq.2283324.n4.nabble.com/how-to-safely-delete-a-cms-MessageListener-object-tp4689939p4690057.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: how to safely delete a cms::MessageListener object

2015-01-15 Thread Steve Rice
Thanks. I considered the sleep idea and will probably go that route. Steve Rice -- View this message in context: http://activemq.2283324.n4.nabble.com/how-to-safely-delete-a-cms-MessageListener-object-tp4689939p4689997.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: how to safely delete a cms::MessageListener object

2015-01-15 Thread Steve Rice
. At that moment, the main thread does not know that there is a concurrent execution of onMessage() and may proceed with de-allocating objects used by onMessage(). Perhaps this window of vulnerability can be closed by using C++11 shared pointers, but that would require modifying the CMS code. Steve

how to safely delete a cms::MessageListener object

2015-01-14 Thread Steve Rice
object in the main thread, the onMessage() function gets called in the separate thread? In other words, how do I stop listening for messages and clean up safely from the main thread? Steve Rice -- View this message in context: http://activemq.2283324.n4.nabble.com/how-to-safely-delete-a-cms