Greetings all,

I have inherited some AMQ CPP client code. Recently we started seeing random
crashes when ActiveMQCPP::initializeLibrary() was being invoked. These
crashes do not always occur.

I used [gdb] and the information relating to this crash is as follows:

------------------------------------------------------------

------------------------------------------------------------

I have started reading through the AMQ CMS CPP documentation, but I don't
see any documentation for the initializeLibrary() method.

However, I do see in code examples, that this initializeLibrary() method is
being invoked as one of the first operations in main().

In the code that I've inheritted, the AMQ client code is abstracted way down
in a helper class and they
invoke the initializeLibrary() every time they are getting read to make a
connection to the broker.

I have a theory that initializeLibrary() should be invoked once and only
once. Moreover to make matters
worse, its possible for multile instances of one of our client AMQ objects
to execute at the same time, since we are a multi-threaded SMP system.

I see a comment in our code above the call that simply says:
        // initializeLibrary() is thread-safe.
however I haven't seen any documentation to prove or disprove this, nor have
I found any documentation to explain how the initializeLibrary() method
should be used.

Can anyone point out documentation for this method?

Thank you in advance for your help,

-=John

--
View this message in context: 
http://activemq.2283324.n4.nabble.com/ActiveMQCPP-initializeLibrary-usage-tp3853754p3853754.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to