Guillaume,
I tried the two solutions you gave me but I am not able to make one of
them running.
First of all, you can find at the end of the mail the servicemix.xml
file I used before trying to move to a standard jbi deployment.
Now what I have done :
I have installed servicemix-jms
I have added a new SU to my BPELSamplesSA : HelloWorldSUForJms
** In the case [1] jms BC
my SU contains a helloworld.wsdl file you can find in attach
(helloworld.wsdl)
and the jbi.xml contains :
<target>
<artifacts-zip>helloworldSUForJms.jar</artifacts-zip>
<component-name>servicemix-jms</component-name>
</target>
When I launch my JMSClient, nothins happens...
I get no result in return, the call hangs...
Before, I was starting servicemix with a servicemix.xml file you can
find in attach (servicemix.xml) and all was running well.
In the new modes, I only updated the queue name but I have updated my
client too.
Can you tell me what is wrong in my files ?
Cheers,
Charles
Guillaume Nodet wrote:
The contents of the SU depends on the target component.
If you use the servicemix-jms BC, you have to deploy a wsdl [1].
If you use lightweight components (in o.a.s.components.jms) you have
to use
the servicemix-lwcontainer component [2].
Guillaume
[1]
https://svn.apache.org/repos/asf/incubator/servicemix/trunk/servicemix-jms/src/test/resources/consumer/jms.wsdl
[2]
https://svn.apache.org/repos/asf/incubator/servicemix/trunk/servicemix-assembly/src/main/release/examples/loan-broker/src/su/servicemix.xml
Charles Souillard wrote:
Guillaume,
I think you mean deploy *a* SU on each BC ?
What should be the format of these SUs ?
In my case a helloworld SU contains only two files : a bpel file and
a wsdl file...
My understanding is if I deploy a SU on a component, this component
will say to the NMR that it now offers this service ? Is that OK ?
If yes I don't understand how I can tell in a standard way to a BC
that my SE is offering a new service.
Can you tell me what I should put into my SU I want to deploy in JMS
BC for example ?
Thanks
Charles
Guillaume Nodet wrote:
Hi Charles !
We have already thought about something related to that.
In the JBI way, you should deploy on SU on each BC you want.
You can deploy them inside the same SA that contains your SU for
your BPEL engine.
To achieve this using the lightweight components, you need to
install the servicemix-lwcontainer, on which you can deploy SU
that are servicemix.xml files (just replacing the <sm:container /> tag
with a <sm:serviceunit /> tag.
The loanbroker and soap-binding samples of the 3.0 distribution
contains
SUs using the servicemix-lwcontainer. You should look at them.
Cheers,
Guillaume Nodet
Charles Souillard wrote:
Hi all,
I want to know how I can make a service available to all SM
components in a standard way :
I have developed an dinstalled a SE
I have deployed a SA containing two SU. Each one offers a service
To test them, I have started SM with a servicemix.xml file which
declares a new component (hellocomponent).
It is a copy paste from the servicemix.xml of the bpel example.
The JMSClient sends a message to the topic on which hellocomponent
is waiting on.
Then the message is well given to my SE which makes the call...
My question is how can I do that without the servicemix.xml file
and is it possible to make my service available to all BCs
installed in servicemix ?
This functionnality will allow users to contact my app in any
transport way they want.
Thanks
Charles
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://xbean.org/schemas/spring/1.0"
xmlns:spring="http://xbean.org/schemas/spring/1.0"
xmlns:sm="http://servicemix.apache.org/config/1.0"
xmlns:echo="urn:echo:bpel:bsoap"
xmlns:hello="urn:helloworld:bpel:bsoap">
<!-- the JBI container -->
<sm:container spring:id="jbi"
rootDir="./wdir"
useMBeanServer="true"
createMBeanServer="true"
installationDirPath="./install"
deploymentDirPath="./deploy"
monitorInstallationDirectory="true"
dumpStats="true"
statsInterval="10"
transactionManager="#transactionManager">
<sm:activationSpecs>
<!-- Subscribe to a JMS destination -->
<sm:activationSpec componentName="echo:echoComponent"
service="echo" destinationService="echo:EchoServiceBP"
destinationEndpoint="echoPT" destinationOperation="echo:echo">
<sm:component>
<bean
class="org.apache.servicemix.components.jms.JmsServiceComponent"
depends-on="broker">
<property name="template">
<bean
class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory">
<ref local="jmsFactory" />
</property>
<property name="defaultDestinationName"
value="demo.org.servicemix.source" />
<property name="pubSubDomain"
value="true" />
</bean>
</property>
</bean>
</sm:component>
</sm:activationSpec>
</sm:activationSpecs>
<sm:activationSpecs>
<!-- Subscribe to a JMS destination -->
<sm:activationSpec componentName="hello:helloComponent"
service="helloworld" destinationService="hello:HelloWorldServiceBP"
destinationEndpoint="HelloWorld" destinationOperation="hello:initiate">
<sm:component>
<bean
class="org.apache.servicemix.components.jms.JmsServiceComponent"
depends-on="broker">
<property name="template">
<bean
class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory">
<ref local="jmsFactory" />
</property>
<property name="defaultDestinationName"
value="demo.org.servicemix.source" />
<property name="pubSubDomain"
value="true" />
</bean>
</property>
</bean>
</sm:component>
</sm:activationSpec>
</sm:activationSpecs>
</sm:container>
<!-- message broker -->
<bean id="broker" class="org.apache.activemq.xbean.BrokerFactoryBean">
<property name="config" value="classpath:activemq.xml" />
</bean>
<bean id="transactionContextManager" class="org.jencks.factory.TransactionContextManagerFactoryBean"/>
<bean id="transactionManager" class="org.jencks.factory.GeronimoTransactionManagerFactoryBean" />
<bean id="jmsFactory"
class="org.apache.activemq.pool.PooledConnectionFactory">
<property name="connectionFactory">
<bean class="org.apache.activemq.ActiveMQConnectionFactory">
<property name="brokerURL">
<value>tcp://localhost:61616</value>
</property>
</bean>
</property>
</bean>
</beans>
<?xml version='1.0' encoding='UTF-8'?>
<definitions name='helloworld'
targetNamespace='urn:helloworld:bpel:bsoap'
xmlns:tns='urn:helloworld:bpel:bsoap'
xmlns:jms='http://servicemix.org/wsdl/jms/'
xmlns='http://schemas.xmlsoap.org/wsdl/'
xmlns:jbi='http://servicemix.org/wsdl/jbi/'>
<portType name='HelloWorld'>
</portType>
<binding name='HelloWorldPTSOAPBinding' type='tns:HelloWorld'>
<jms:binding />
</binding>
<service name='HelloWorldServiceBP'>
<port name='HelloWorld' binding='tns:HelloWorldPTSOAPBinding'>
<jms:address destinationStyle="queue"
jmsProviderDestinationName="HelloWorldQueue"
jndiConnectionFactoryName="JQCF"/>
<jbi:endpoint role="provider"/>
</port>
</service>
</definitions>