activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From BennyAR <benny.hjert...@atchik-realtime.com>
Subject ObjectMessage and sharing Class between client and server
Date Mon, 22 Mar 2010 12:12:20 GMT

Perhaps I've missed something, but I cannot find any documentation on how to
successfully send a custom object (some simple POJO) between a client and
server using an ActiveMQ broker. 

They are not running in the same JVM, so how do you cast the object without
getting
Caught:javax.jms.JMSException: Failed to build body from content.
Serializable class not available to broker. Reason:
java.lang.ClassNotFoundException: com.blah.test.MyObj

i.e. both the sender and receiver must know about the the POJO class
definition. 

Is there a way to add classes to the broker classpath? Or do I add a jar
file containing the POJO in the lib folder of activemq? Or do I need to use
Spring or Camel to create some kind of application context?
-- 
View this message in context: http://old.nabble.com/ObjectMessage-and-sharing-Class-between-client-and-server-tp27985506p27985506.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message