You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by bgoetzmann <bg...@sophia.symag.com> on 2007/07/02 18:56:34 UTC
Test on the servicemix-wsn2005 component
Hello,
Testing the servicemix-wsn2005 component in ServiceMix 3.1, I'm facing a
problem for the servicemix-wsn2005-3.1-incubating.jar library.
Putting the servicemix-wsn2005-3.1-incubating-installer.zip in the install
directroy and deploying a SU on the servicemix-wsn2005 component, all is
correct. From the outsite on the JBI bus I'm able to subscribe on a topic
and send notification messages.
I'm developing a POJO (that must deployed on the servicemix-jsr181
component) to be able to send a notification message to the notification
broker with this code :
try {
NotificationBroker wsnBroker = new NotificationBroker(context);
wsnBroker.notify("myTopic", parse("<hello>Bonjour !</hello>"));
} catch (Exception e) {
e.printStackTrace();
}
But when deploying the corresponding SA I get a NoClassDefFoundError for the
NotificationBroker class :
java.lang.NoClassDefFoundError:
org/apache/servicemix/wsn/client/NotificationBroker
This class commes form the servicemix-wsn2005-3.1-incubating.jar library.
So if a copy the servicemix-wsn2005-3.1-incubating.jar library (coming from
servicemix-wsn2005-3.1-incubating-installer.zip) in the lib, and restart
ServiceMix I get an exception at the installation of the servicemix-wsn2005
component (something like BaseComponent not found).
How can I shared the servicemix-wsn2005-3.1-incubating.jar library ?
Any idea about this problem ?
Thank you.
--
View this message in context: http://www.nabble.com/Test-on-the-servicemix-wsn2005-component-tf4013469s12049.html#a11397594
Sent from the ServiceMix - User mailing list archive at Nabble.com.
Re: Test on the servicemix-wsn2005 component
Posted by bgoetzmann <bg...@sophia.symag.com>.
Finally, this thread helped me :
http://www.nabble.com/Shared-Libraries-usable-by-deployed-SUs--tf2326969s12049.html#a6473694
In my POJO's SU, I've added the servicemix-wsn2005-3.1-incubating.jar file,
so my xbean.xml refrences it :
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns:jsr181="http://servicemix.apache.org/jsr181/1.0"
xmlns:mp="http://odelia-technologies.com/metaphora">
<property name="context" ref="context" />
<classpath>
<location>service.jar</location>
<location>servicemix-wsn2005-3.1-incubating.jar</location>
</classpath>
<jsr181:endpoint pojoClass="com.odelia.metaphora.ServiceMtom"
annotations="none" service="mp:serviceMtom" endpoint="serviceMtomEP"
mtomEnabled="true"/>
</beans>
What I find interesting is one can send a message notification from inside
the bus using API.
Hope this help.
bgoetzmann wrote:
>
> Hello,
>
> Testing the servicemix-wsn2005 component in ServiceMix 3.1, I'm facing a
> problem for the servicemix-wsn2005-3.1-incubating.jar library.
>
> Putting the servicemix-wsn2005-3.1-incubating-installer.zip in the install
> directroy and deploying a SU on the servicemix-wsn2005 component, all is
> correct. From the outsite on the JBI bus I'm able to subscribe on a topic
> and send notification messages.
>
> I'm developing a POJO (that must deployed on the servicemix-jsr181
> component) to be able to send a notification message to the notification
> broker with this code :
>
> try {
> NotificationBroker wsnBroker = new NotificationBroker(context);
> wsnBroker.notify("myTopic", parse("<hello>Bonjour !</hello>"));
> } catch (Exception e) {
> e.printStackTrace();
> }
>
> But when deploying the corresponding SA I get a NoClassDefFoundError for
> the NotificationBroker class :
> java.lang.NoClassDefFoundError:
> org/apache/servicemix/wsn/client/NotificationBroker
> This class commes form the servicemix-wsn2005-3.1-incubating.jar library.
>
> So if a copy the servicemix-wsn2005-3.1-incubating.jar library (coming
> from servicemix-wsn2005-3.1-incubating-installer.zip) in the lib, and
> restart ServiceMix I get an exception at the installation of the
> servicemix-wsn2005 component (something like BaseComponent not found).
>
> How can I shared the servicemix-wsn2005-3.1-incubating.jar library ?
> Any idea about this problem ?
>
> Thank you.
>
>
--
View this message in context: http://www.nabble.com/Test-on-the-servicemix-wsn2005-component-tf4013469s12049.html#a11401108
Sent from the ServiceMix - User mailing list archive at Nabble.com.