OK, got it. Thank you very much!!

bsnyder wrote:
> 
> On 7/12/07, smilingsky <[EMAIL PROTECTED]> wrote:
>>
>> Hello,
>>
>> Since I have a perl client to access services through servicemix-jms, I
>> think I need to enable Stomp access to servicemix-jms. I read the
>> directions
>> of enabling the ActiveMQ broker for Stomp from
>> http://activemq.apache.org/stomp.html. I also find the example on
>> http://incubator.apache.org/servicemix/jms-binding-configuration.html.
>> Based
>> on my understanding, I have my xbean.xml configuration like:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <beans xmlns:sm="http://servicemix.apache.org/config/1.0";
>>         xmlns:jms="http://servicemix.apache.org/jms/1.0";
>>         xmlns:amq="http://activemq.org/config/1.0";
>>         xmlns:rtdemo="http://rtdemo.abacus.com/rtdemo";>
>>         <!-- JMS POLLER - CONSUMER -->
>>         <jms:endpoint service="rtdemo:MyConsumer" endpoint="MyConsumer"
>>                 targetService="rtdemo:RTDemo" targetEndpoint="Soap"
>> role="consumer"
>>                 defaultMep="http://www.w3.org/2004/08/wsdl/in-out";
>>                 destinationStyle="queue" soap="true"
>>                 jmsProviderDestinationName="demo.com.abacus.source"
>>                 connectionFactory="#rtdemoConnFactory" />
>>         <!-- JMS SENDER - PROVIDER -->
>>         <jms:endpoint service="rtdemo:MyProvider" endpoint="MyProvider"
>>                 role="provider"
>> defaultMep="http://www.w3.org/2004/08/wsdl/in-out";
>>                 destinationStyle="queue"
>>                 jmsProviderDestinationName="demo.com.abacus.result"
>>                 connectionFactory="#rtdemoConnFactory" />
>>         <!-- FACTORY BEAN -->
>>         <bean id="rtdemoConnFactory"
>>                 class="org.apache.activemq.ActiveMQConnectionFactory">
>>                 <property name="brokerURL" value="tcp://localhost:61616"
>> />
>>         </bean>
>>         <!-- BROKER BEAN -->
>>         <amq:broker id="rtdemoBroker" persistent="false">
>>                 <amq:transportConnectors>
>>                         <amq:transportConnector
>> uri="tcp://localhost:61616" />
>>                         <amq:transportConnector
>> uri="stomp://localhost:61613" />
>>                 </amq:transportConnectors>
>>         </amq:broker>
>> </beans>
>>
>> However, it seems <amq:broker> will re-create a broker "localhost" after
>> ConnFactory creates one. The error message is:
>>
>> 2007-07-12 11:34:42,543 [main           ] ERROR BrokerService
>> - Failed to start ActiveMQ JMS Message Broker. Reason:
>> javax.management.InstanceAlreadyExistsException:
>> org.apache.activemq:BrokerName=localhost,Type=Broker
>> javax.management.InstanceAlreadyExistsException:
>> org.apache.activemq:BrokerName=localhost,Type=Broker
>>         at
>> com.sun.jmx.mbeanserver.Repository.addMBean(Repository.java:453)
> 
> 
> This is because ActiveMQ is already started inside of ServiceMix. See
> conf/activemq.xml for the ActiveMQ configuration. Just add a transport
> connector for STOMP. Below is an example:
> 
> <amq:transportConnector uri="stomp://localhost:61613 />
> 
> Just add that to the <transportConnectors> element and ActiveMQ will
> provide access via STOMP on port 61613.
> 
> Bruce
> -- 
> perl -e 'print
> unpack("u30","D0G)[EMAIL PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
> );'
> 
> Apache Geronimo - http://geronimo.apache.org/
> Apache ActiveMQ - http://activemq.org/
> Apache ServiceMix - http://servicemix.org/
> Castor - http://castor.org/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Broker-Config-for-servicemix-jms-tf4069758s12049.html#a11566403
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to