You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by navigator09 <ga...@gmail.com> on 2008/07/23 12:00:11 UTC

understanding the working of routing slip in servicemix-eip

Hi,

  I am implementing routing slip pattern in the application. In the pattern
I have routed the output of the webservice to a jms queue exposed as a
service using the jms-su. A camel router is listing to the queue and
processing the response and at the same time I also have a python script
listiing to messages from the same queue.

  I requirement is the messages on the queue needs to be processed further
by the camel router and at the same time should be available for the python
script for display. But the messages routed by the routing slip to the queue
are available to the camel router only. They are not even registered on the
jconsole queue status.

  Are messages sent internally thorough su not available to the external
listeners?



The configuration of routing slip

<eip:static-routing-slip service="replaceMe:routingSlip"
endpoint="endpoint">
    <eip:targets>
      <eip:exchange-target service="scmservice:SCMService" />
      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
    </eip:targets>
  </eip:static-routing-slip>



Regards,
Ganesh

-- 
View this message in context: http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: understanding the working of routing slip in servicemix-eip

Posted by Guillaume Nodet <gn...@gmail.com>.
Opps, there is a typo in the doc.  it should be "pubSubDomain" with a
'n' at the end.

On Wed, Jul 23, 2008 at 2:03 PM, navigator09 <ga...@gmail.com> wrote:
>
>
>
>  How do I configure servicemix-jms su to point to a topic? when I used the
> "pubSubDomaim " property in the jms provider it says no such property
> available.
>
> Regards,
> Ganesh
>
> gnodet wrote:
>>
>> Right, or you may be able to use the EIP recipient list pattern to
>> forward a copy of the exchange to multiple JBI endpoints.
>>
>> On Wed, Jul 23, 2008 at 12:30 PM, Manuel EVENO <ma...@gmail.com>
>> wrote:
>>> If you need multiple consumer of a message, you should use JMS Topic
>>> instead
>>> of JMS Queue.
>>> See http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JMS3.html#wp78715
>>>
>>> On Wed, Jul 23, 2008 at 12:00 PM, navigator09 <ga...@gmail.com>
>>> wrote:
>>>
>>>>
>>>> Hi,
>>>>
>>>>  I am implementing routing slip pattern in the application. In the
>>>> pattern
>>>> I have routed the output of the webservice to a jms queue exposed as a
>>>> service using the jms-su. A camel router is listing to the queue and
>>>> processing the response and at the same time I also have a python script
>>>> listiing to messages from the same queue.
>>>>
>>>>  I requirement is the messages on the queue needs to be processed
>>>> further
>>>> by the camel router and at the same time should be available for the
>>>> python
>>>> script for display. But the messages routed by the routing slip to the
>>>> queue
>>>> are available to the camel router only. They are not even registered on
>>>> the
>>>> jconsole queue status.
>>>>
>>>>  Are messages sent internally thorough su not available to the external
>>>> listeners?
>>>>
>>>>
>>>>
>>>> The configuration of routing slip
>>>>
>>>> <eip:static-routing-slip service="replaceMe:routingSlip"
>>>> endpoint="endpoint">
>>>>    <eip:targets>
>>>>      <eip:exchange-target service="scmservice:SCMService" />
>>>>      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
>>>>    </eip:targets>
>>>>  </eip:static-routing-slip>
>>>>
>>>>
>>>>
>>>> Regards,
>>>> Ganesh
>>>>
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
>>>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>>>
>>>>
>>>
>>
>>
>>
>> --
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
>>
>>
>
> --
> View this message in context: http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18609217.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Re: understanding the working of routing slip in servicemix-eip

Posted by navigator09 <ga...@gmail.com>.


  How do I configure servicemix-jms su to point to a topic? when I used the
"pubSubDomaim " property in the jms provider it says no such property
available.

Regards,
Ganesh

gnodet wrote:
> 
> Right, or you may be able to use the EIP recipient list pattern to
> forward a copy of the exchange to multiple JBI endpoints.
> 
> On Wed, Jul 23, 2008 at 12:30 PM, Manuel EVENO <ma...@gmail.com>
> wrote:
>> If you need multiple consumer of a message, you should use JMS Topic
>> instead
>> of JMS Queue.
>> See http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JMS3.html#wp78715
>>
>> On Wed, Jul 23, 2008 at 12:00 PM, navigator09 <ga...@gmail.com>
>> wrote:
>>
>>>
>>> Hi,
>>>
>>>  I am implementing routing slip pattern in the application. In the
>>> pattern
>>> I have routed the output of the webservice to a jms queue exposed as a
>>> service using the jms-su. A camel router is listing to the queue and
>>> processing the response and at the same time I also have a python script
>>> listiing to messages from the same queue.
>>>
>>>  I requirement is the messages on the queue needs to be processed
>>> further
>>> by the camel router and at the same time should be available for the
>>> python
>>> script for display. But the messages routed by the routing slip to the
>>> queue
>>> are available to the camel router only. They are not even registered on
>>> the
>>> jconsole queue status.
>>>
>>>  Are messages sent internally thorough su not available to the external
>>> listeners?
>>>
>>>
>>>
>>> The configuration of routing slip
>>>
>>> <eip:static-routing-slip service="replaceMe:routingSlip"
>>> endpoint="endpoint">
>>>    <eip:targets>
>>>      <eip:exchange-target service="scmservice:SCMService" />
>>>      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
>>>    </eip:targets>
>>>  </eip:static-routing-slip>
>>>
>>>
>>>
>>> Regards,
>>> Ganesh
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
>>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>>
>>>
>>
> 
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18609217.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: understanding the working of routing slip in servicemix-eip

Posted by Guillaume Nodet <gn...@gmail.com>.
If you use a request / reply, the jms provider configured in the
routing slip will wait for a JMS message as a response.
However, in your camel route, you have no JMS endpoint used at all, be
it as a consumer or as a provider.
The url "jbi:endpoint:urn:org:apache:servicemix:tutorial:camel:jms:consumer"
will create a JBI endpoint and the exchanges sent to this endpoint
will be processed by camel.  If you want to consumer a JMS message
from camel, you need to use "jms:xxx" or "activemq:xxx" as a URL.

On Thu, Jul 24, 2008 at 12:41 PM, navigator09 <ga...@gmail.com> wrote:
>
> Hi nodet,
>
>  I have configured a jms topic using the jms-su. I have tested it by
> sending messages to the topic from the jconsole. They work fine. But when I
> route the reply from the webservice to the jms provider service the  topic
> does not recieve the message. This I confirmed by checking the status of the
> topic in jconsole. However, the route builder listening to the condumer jms
> end point is able to get the normalised message. I think this is because the
> message is forwarded to internal endpoint only. How do I forwared messages
> to external endpoint so that the topic configured to this end point gets it?
>
> the code of routeing slip
>
> <eip:static-routing-slip service="replaceMe:routingSlip"
> endpoint="endpoint">
>    <eip:targets>
>      <eip:exchange-target service="scmservice:SCMService" />
>      <eip:exchange-target service="tutorial:jms:provider" />
>    </eip:targets>
>  </eip:static-routing-slip>
>
>
> and that of route builder
>
>
>         public void configure() {
>
>
>
>        from("jbi:endpoint:urn:org:apache:servicemix:tutorial:camel:jms:consumer")
>            .to("log:tutorial-jbi")
>            //.convertBodyTo(DOMSource.class)
>            //.to("log:tutorial-domsource")
>             .convertBodyTo(String.class)
>            .to("log:tutorial-string");
>
>
>   }
>
> Regards,
> Ganesh
>
>
>
>
>
>
>  Also I have read that
>
> gnodet wrote:
>>
>> Right, or you may be able to use the EIP recipient list pattern to
>> forward a copy of the exchange to multiple JBI endpoints.
>>
>> On Wed, Jul 23, 2008 at 12:30 PM, Manuel EVENO <ma...@gmail.com>
>> wrote:
>>> If you need multiple consumer of a message, you should use JMS Topic
>>> instead
>>> of JMS Queue.
>>> See http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JMS3.html#wp78715
>>>
>>> On Wed, Jul 23, 2008 at 12:00 PM, navigator09 <ga...@gmail.com>
>>> wrote:
>>>
>>>>
>>>> Hi,
>>>>
>>>>  I am implementing routing slip pattern in the application. In the
>>>> pattern
>>>> I have routed the output of the webservice to a jms queue exposed as a
>>>> service using the jms-su. A camel router is listing to the queue and
>>>> processing the response and at the same time I also have a python script
>>>> listiing to messages from the same queue.
>>>>
>>>>  I requirement is the messages on the queue needs to be processed
>>>> further
>>>> by the camel router and at the same time should be available for the
>>>> python
>>>> script for display. But the messages routed by the routing slip to the
>>>> queue
>>>> are available to the camel router only. They are not even registered on
>>>> the
>>>> jconsole queue status.
>>>>
>>>>  Are messages sent internally thorough su not available to the external
>>>> listeners?
>>>>
>>>>
>>>>
>>>> The configuration of routing slip
>>>>
>>>> <eip:static-routing-slip service="replaceMe:routingSlip"
>>>> endpoint="endpoint">
>>>>    <eip:targets>
>>>>      <eip:exchange-target service="scmservice:SCMService" />
>>>>      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
>>>>    </eip:targets>
>>>>  </eip:static-routing-slip>
>>>>
>>>>
>>>>
>>>> Regards,
>>>> Ganesh
>>>>
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
>>>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>>>
>>>>
>>>
>>
>>
>>
>> --
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
>>
>>
>
> --
> View this message in context: http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18629311.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Re: understanding the working of routing slip in servicemix-eip

Posted by navigator09 <ga...@gmail.com>.
Hi nodet,

  I have configured a jms topic using the jms-su. I have tested it by
sending messages to the topic from the jconsole. They work fine. But when I
route the reply from the webservice to the jms provider service the  topic
does not recieve the message. This I confirmed by checking the status of the
topic in jconsole. However, the route builder listening to the condumer jms
end point is able to get the normalised message. I think this is because the
message is forwarded to internal endpoint only. How do I forwared messages
to external endpoint so that the topic configured to this end point gets it?

the code of routeing slip 

<eip:static-routing-slip service="replaceMe:routingSlip"
endpoint="endpoint">
    <eip:targets>
      <eip:exchange-target service="scmservice:SCMService" />
      <eip:exchange-target service="tutorial:jms:provider" />
    </eip:targets>
  </eip:static-routing-slip>


and that of route builder


	 public void configure() {
	 
     
	    
	from("jbi:endpoint:urn:org:apache:servicemix:tutorial:camel:jms:consumer")       
	    .to("log:tutorial-jbi")
	    //.convertBodyTo(DOMSource.class)
	    //.to("log:tutorial-domsource")
	     .convertBodyTo(String.class)
	    .to("log:tutorial-string"); 
	
	
   }

Regards,
Ganesh




  

  Also I have read that 

gnodet wrote:
> 
> Right, or you may be able to use the EIP recipient list pattern to
> forward a copy of the exchange to multiple JBI endpoints.
> 
> On Wed, Jul 23, 2008 at 12:30 PM, Manuel EVENO <ma...@gmail.com>
> wrote:
>> If you need multiple consumer of a message, you should use JMS Topic
>> instead
>> of JMS Queue.
>> See http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JMS3.html#wp78715
>>
>> On Wed, Jul 23, 2008 at 12:00 PM, navigator09 <ga...@gmail.com>
>> wrote:
>>
>>>
>>> Hi,
>>>
>>>  I am implementing routing slip pattern in the application. In the
>>> pattern
>>> I have routed the output of the webservice to a jms queue exposed as a
>>> service using the jms-su. A camel router is listing to the queue and
>>> processing the response and at the same time I also have a python script
>>> listiing to messages from the same queue.
>>>
>>>  I requirement is the messages on the queue needs to be processed
>>> further
>>> by the camel router and at the same time should be available for the
>>> python
>>> script for display. But the messages routed by the routing slip to the
>>> queue
>>> are available to the camel router only. They are not even registered on
>>> the
>>> jconsole queue status.
>>>
>>>  Are messages sent internally thorough su not available to the external
>>> listeners?
>>>
>>>
>>>
>>> The configuration of routing slip
>>>
>>> <eip:static-routing-slip service="replaceMe:routingSlip"
>>> endpoint="endpoint">
>>>    <eip:targets>
>>>      <eip:exchange-target service="scmservice:SCMService" />
>>>      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
>>>    </eip:targets>
>>>  </eip:static-routing-slip>
>>>
>>>
>>>
>>> Regards,
>>> Ganesh
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
>>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>>
>>>
>>
> 
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18629311.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: understanding the working of routing slip in servicemix-eip

Posted by Guillaume Nodet <gn...@gmail.com>.
Right, or you may be able to use the EIP recipient list pattern to
forward a copy of the exchange to multiple JBI endpoints.

On Wed, Jul 23, 2008 at 12:30 PM, Manuel EVENO <ma...@gmail.com> wrote:
> If you need multiple consumer of a message, you should use JMS Topic instead
> of JMS Queue.
> See http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JMS3.html#wp78715
>
> On Wed, Jul 23, 2008 at 12:00 PM, navigator09 <ga...@gmail.com>
> wrote:
>
>>
>> Hi,
>>
>>  I am implementing routing slip pattern in the application. In the pattern
>> I have routed the output of the webservice to a jms queue exposed as a
>> service using the jms-su. A camel router is listing to the queue and
>> processing the response and at the same time I also have a python script
>> listiing to messages from the same queue.
>>
>>  I requirement is the messages on the queue needs to be processed further
>> by the camel router and at the same time should be available for the python
>> script for display. But the messages routed by the routing slip to the
>> queue
>> are available to the camel router only. They are not even registered on the
>> jconsole queue status.
>>
>>  Are messages sent internally thorough su not available to the external
>> listeners?
>>
>>
>>
>> The configuration of routing slip
>>
>> <eip:static-routing-slip service="replaceMe:routingSlip"
>> endpoint="endpoint">
>>    <eip:targets>
>>      <eip:exchange-target service="scmservice:SCMService" />
>>      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
>>    </eip:targets>
>>  </eip:static-routing-slip>
>>
>>
>>
>> Regards,
>> Ganesh
>>
>> --
>> View this message in context:
>> http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>
>>
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Re: understanding the working of routing slip in servicemix-eip

Posted by Manuel EVENO <ma...@gmail.com>.
If you need multiple consumer of a message, you should use JMS Topic instead
of JMS Queue.
See http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JMS3.html#wp78715

On Wed, Jul 23, 2008 at 12:00 PM, navigator09 <ga...@gmail.com>
wrote:

>
> Hi,
>
>  I am implementing routing slip pattern in the application. In the pattern
> I have routed the output of the webservice to a jms queue exposed as a
> service using the jms-su. A camel router is listing to the queue and
> processing the response and at the same time I also have a python script
> listiing to messages from the same queue.
>
>  I requirement is the messages on the queue needs to be processed further
> by the camel router and at the same time should be available for the python
> script for display. But the messages routed by the routing slip to the
> queue
> are available to the camel router only. They are not even registered on the
> jconsole queue status.
>
>  Are messages sent internally thorough su not available to the external
> listeners?
>
>
>
> The configuration of routing slip
>
> <eip:static-routing-slip service="replaceMe:routingSlip"
> endpoint="endpoint">
>    <eip:targets>
>      <eip:exchange-target service="scmservice:SCMService" />
>      <eip:exchange-target service="tutorial:jms" endpoint="provider"/>
>    </eip:targets>
>  </eip:static-routing-slip>
>
>
>
> Regards,
> Ganesh
>
> --
> View this message in context:
> http://www.nabble.com/understanding-the-working-of-routing-slip-in-servicemix-eip-tp18607456p18607456.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>