You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by Gert Vanthienen <ge...@skynet.be> on 2007/07/24 08:35:28 UTC

Re: Usage of lightweight components?

L.S.,


Forwarding this message to the users mailing list, because it isn't 
really related to development of ServiceMix itself...

If you want to deploy a JMS consumer endpoint, you should do so in a SU 
that targets servicemix-jms.  In your case, you should have two SUs, one 
targeted at servicemix-bean and another targeted at servicemix-jms.

Your SA should contain both SU archives, as well as a jbi.xml file that 
specifies the JBI component to target.  Can you check if your SA has 
this file and the necessary information in it?  Does ServiceMix also log 
the SU being deployed succesfully?


Gert

kiwisurfer wrote:
> Hi,
> 
> Can someone explain the relationship between deployment and registration?
> 
>>>From earlier posts about lightweight components, it was suggested that the
> servicemix-beancontainer was a more full featured component for hosting
> light weight objects. So I have written a simple SA and a SU, that is hosted
> via the servicemix-beancontainer. 
> 
> My xbean.xml file in the SU exposes 2 endpoints: a standard JMS consumer,
> and a bean endpoint that points to my ComponentSupport derived class.
> 
> Having dropped the SA into the hot deploy folder, ServiceMix logs that the
> SA was successfully deployed. When using a JMX console, I don't see the JMS
> endpoint or my bean endpoint and therefore assume that my SA did not
> successfully register these endpoints.
> 
> This may well have something to do with configuration not being correct, but
> I am unsure at this point how ServiceMix carries out this step, and
> therefore what I need to be looking for to correct.
> 
> 
> xbean.xml
> <?xml version="1.0" encoding="UTF-8"?>
> <beans xmlns:bean="http://servicemix.apache.org/bean/1.0"
>        xmlns:lb="http://mine.com/catalogService"
>        xmlns:jms="http://servicemix.apache.org/jms/1.0">
> 
>  <jms:endpoint service="test:MyConsumerService"
>               endpoint="jms"
>               targetService="test:MyConsumerService"
>               targetEndpoint="endpoint"
>               role="consumer" 
>               destinationStyle="queue"
>               jmsProviderDestinationName="queue/A"
>               jndiConnectionFactoryName="ConnectionFactory"
>               defaultMep="http://www.w3.org/2004/08/wsdl/in-out"
>               defaultOperation="test:Echo" 
>               description="My first test"/>
> 
>   <bean:endpoint service="mine:catalogService" endpoint="endpoint"
> bean="#catalogServiceBean"/>
>   <bean id="catalogServiceBean"
> class="com.mine.streamline.CatalogServiceEngineImpl"/>
> </beans>