[zeromq-dev] Error handling in client code.

Theo Schlossnagle theo at omniti.com
Thu May 7 18:06:25 CEST 2009


I'm attempting to prototype an application using zeromq for  
interprocess messaging.  I have a C client and a Java Client.  I've  
got the code working, but I'm running into a wall with some of the  
assertions in the code.

In my Java process, when I: Zmq zmq = new Zmq("localhost"); it works  
fine when zmq_server is running.  However, when zmq_server isn't  
running I don't seem to have an opportunity to robustly handle this  
failure condition in my application -- it abort()s within JNI.  Much  
to my surprise, I also get asserts in stead of errors for my client  
code to compensate for.  What's the correct approach here?  I need to  
able to robustly continue my application when zmq isn't around.

Thanks!

--
Theo Schlossnagle
http://omniti.com/is/theo-schlossnagle
p: +1.443.325.1357 x201   f: +1.410.872.4911








More information about the zeromq-dev mailing list