[zeromq-dev] Ubuntu 11.04: ZeroMQ Java Binding

Umut Aydin aydinumut82 at gmail.com
Mon Oct 10 08:52:37 CEST 2011


Hello Everyone,

I have installed latest versions of ZeroMQ and JZMQ from source codes and it
seems that all pieces are in right folder.

/usr/local/lib/libzmq.so (with others)
/usr/local/lib/libjzmq.so (with others)
/usr/local/share/java/zmq.jar

There is no problem with compiling example:
$ javac -classpath /usr/local/share/java/zmq.jar hwserver.java

But I get this error when I try to run it.
Exception in thread "main" java.lang.NoClassDefFoundError: hwserver
Caused by: java.lang.ClassNotFoundException: hwserver
 at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
 at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
Could not find the main class: hwserver.  Program will exit.

Python binding is really easy to use but I couldn't get java binding work
somehow. Any idea?

Regards,
-Umut
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20111010/6f03f9a5/attachment.htm>


More information about the zeromq-dev mailing list