You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by pradeep <pr...@gmail.com> on 2006/09/07 11:03:21 UTC

onMessageExchange and transform method

I am new to Servicemix. I am confused between onMessageExchange and the
transform method. When I should  them ?thanks
-- 
View this message in context: http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6186827
Sent from the ServiceMix - User forum at Nabble.com.


Re: onMessageExchange and transform method

Posted by Guillaume Nodet <gn...@gmail.com>.
The TransformComponentSupport handle both InOnly and InOut.
When an InOut is received, it will send the transformed message
in the " out" message.  When an InOnly is received, it will send
the transformed message in a new InOnly exchange that will
be sent to the targetService configured on the activationSpec.

On 9/8/06, pradeep <pr...@gmail.com> wrote:
>
>
> Thanks gnodet. When you say "..end back the transformed message..", are
> you
> talking about the response object. So in request-response scenario are you
> suggesting the use TransformComponentSupport ?
>
>
> gnodet wrote:
> >
> > Sure, but if your component acts as a transformer (receives a message
> > process it and send back the transformed message), it would be
> > easier to inherit the TransformComponentSupport...
> >
> > On 9/8/06, pradeep <pr...@gmail.com> wrote:
> >>
> >>
> >> Let me explain my application. My application send messages to and
> >> process
> >> over jms bus. Is onmessahgeExchange() sufficient?
> >>
> >> Pradeep
> >>
> >>
> >> gnodet wrote:
> >> >
> >> > The Bank inherit the TransformComponentSupport whereas
> >> > the LoanBroker inherit the ComponentSupport
> >> > (which is a super class of TransformComponentSupport).
> >> > The TransformComponentSupport already implements
> >> > the onMessage and defines an abstract method which
> >> > must be implemented by Bank.
> >> >
> >> > On 9/8/06, pradeep <pr...@gmail.com> wrote:
> >> >>
> >> >>
> >> >> Well I was looking into loan broker example. In the Bank class
> >> >> transform()
> >> >> is
> >> >> used whereas in the LoanBroker onMessage() is used. Why is this.
> Sorry
> >> if
> >> >> the question is stupid.
> >> >>
> >> >>
> >> >> johper wrote:
> >> >> >
> >> >> > Maybe you can tell a little bit more in detail what you would like
> >> to
> >> >> do?
> >> >> >
> >> >> >
> >> >> > pradeep wrote:
> >> >> >>
> >> >> >> I am new to Servicemix. I am confused between onMessageExchange
> and
> >> >> the
> >> >> >> transform method. When I should  them ?thanks
> >> >> >>
> >> >> >
> >> >> >
> >> >>
> >> >> --
> >> >> View this message in context:
> >> >>
> >>
> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6205627
> >> >> Sent from the ServiceMix - User forum at Nabble.com.
> >> >>
> >> >>
> >> >
> >> >
> >> > --
> >> > Cheers,
> >> > Guillaume Nodet
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6206036
> >> Sent from the ServiceMix - User forum at Nabble.com.
> >>
> >>
> >
> >
> > --
> > Cheers,
> > Guillaume Nodet
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6206301
> Sent from the ServiceMix - User forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: onMessageExchange and transform method

Posted by pradeep <pr...@gmail.com>.
Thanks gnodet. When you say "..end back the transformed message..", are you
talking about the response object. So in request-response scenario are you
suggesting the use TransformComponentSupport ? 


gnodet wrote:
> 
> Sure, but if your component acts as a transformer (receives a message
> process it and send back the transformed message), it would be
> easier to inherit the TransformComponentSupport...
> 
> On 9/8/06, pradeep <pr...@gmail.com> wrote:
>>
>>
>> Let me explain my application. My application send messages to and
>> process
>> over jms bus. Is onmessahgeExchange() sufficient?
>>
>> Pradeep
>>
>>
>> gnodet wrote:
>> >
>> > The Bank inherit the TransformComponentSupport whereas
>> > the LoanBroker inherit the ComponentSupport
>> > (which is a super class of TransformComponentSupport).
>> > The TransformComponentSupport already implements
>> > the onMessage and defines an abstract method which
>> > must be implemented by Bank.
>> >
>> > On 9/8/06, pradeep <pr...@gmail.com> wrote:
>> >>
>> >>
>> >> Well I was looking into loan broker example. In the Bank class
>> >> transform()
>> >> is
>> >> used whereas in the LoanBroker onMessage() is used. Why is this. Sorry
>> if
>> >> the question is stupid.
>> >>
>> >>
>> >> johper wrote:
>> >> >
>> >> > Maybe you can tell a little bit more in detail what you would like
>> to
>> >> do?
>> >> >
>> >> >
>> >> > pradeep wrote:
>> >> >>
>> >> >> I am new to Servicemix. I am confused between onMessageExchange and
>> >> the
>> >> >> transform method. When I should  them ?thanks
>> >> >>
>> >> >
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6205627
>> >> Sent from the ServiceMix - User forum at Nabble.com.
>> >>
>> >>
>> >
>> >
>> > --
>> > Cheers,
>> > Guillaume Nodet
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6206036
>> Sent from the ServiceMix - User forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6206301
Sent from the ServiceMix - User forum at Nabble.com.


Re: onMessageExchange and transform method

Posted by Guillaume Nodet <gn...@gmail.com>.
Sure, but if your component acts as a transformer (receives a message
process it and send back the transformed message), it would be
easier to inherit the TransformComponentSupport...

On 9/8/06, pradeep <pr...@gmail.com> wrote:
>
>
> Let me explain my application. My application send messages to and process
> over jms bus. Is onmessahgeExchange() sufficient?
>
> Pradeep
>
>
> gnodet wrote:
> >
> > The Bank inherit the TransformComponentSupport whereas
> > the LoanBroker inherit the ComponentSupport
> > (which is a super class of TransformComponentSupport).
> > The TransformComponentSupport already implements
> > the onMessage and defines an abstract method which
> > must be implemented by Bank.
> >
> > On 9/8/06, pradeep <pr...@gmail.com> wrote:
> >>
> >>
> >> Well I was looking into loan broker example. In the Bank class
> >> transform()
> >> is
> >> used whereas in the LoanBroker onMessage() is used. Why is this. Sorry
> if
> >> the question is stupid.
> >>
> >>
> >> johper wrote:
> >> >
> >> > Maybe you can tell a little bit more in detail what you would like to
> >> do?
> >> >
> >> >
> >> > pradeep wrote:
> >> >>
> >> >> I am new to Servicemix. I am confused between onMessageExchange and
> >> the
> >> >> transform method. When I should  them ?thanks
> >> >>
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6205627
> >> Sent from the ServiceMix - User forum at Nabble.com.
> >>
> >>
> >
> >
> > --
> > Cheers,
> > Guillaume Nodet
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6206036
> Sent from the ServiceMix - User forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: onMessageExchange and transform method

Posted by pradeep <pr...@gmail.com>.
Let me explain my application. My application send messages to and process
over jms bus. Is onmessahgeExchange() sufficient?

Pradeep


gnodet wrote:
> 
> The Bank inherit the TransformComponentSupport whereas
> the LoanBroker inherit the ComponentSupport
> (which is a super class of TransformComponentSupport).
> The TransformComponentSupport already implements
> the onMessage and defines an abstract method which
> must be implemented by Bank.
> 
> On 9/8/06, pradeep <pr...@gmail.com> wrote:
>>
>>
>> Well I was looking into loan broker example. In the Bank class
>> transform()
>> is
>> used whereas in the LoanBroker onMessage() is used. Why is this. Sorry if
>> the question is stupid.
>>
>>
>> johper wrote:
>> >
>> > Maybe you can tell a little bit more in detail what you would like to
>> do?
>> >
>> >
>> > pradeep wrote:
>> >>
>> >> I am new to Servicemix. I am confused between onMessageExchange and
>> the
>> >> transform method. When I should  them ?thanks
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6205627
>> Sent from the ServiceMix - User forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6206036
Sent from the ServiceMix - User forum at Nabble.com.


Re: onMessageExchange and transform method

Posted by Guillaume Nodet <gn...@gmail.com>.
The Bank inherit the TransformComponentSupport whereas
the LoanBroker inherit the ComponentSupport
(which is a super class of TransformComponentSupport).
The TransformComponentSupport already implements
the onMessage and defines an abstract method which
must be implemented by Bank.

On 9/8/06, pradeep <pr...@gmail.com> wrote:
>
>
> Well I was looking into loan broker example. In the Bank class transform()
> is
> used whereas in the LoanBroker onMessage() is used. Why is this. Sorry if
> the question is stupid.
>
>
> johper wrote:
> >
> > Maybe you can tell a little bit more in detail what you would like to
> do?
> >
> >
> > pradeep wrote:
> >>
> >> I am new to Servicemix. I am confused between onMessageExchange and the
> >> transform method. When I should  them ?thanks
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6205627
> Sent from the ServiceMix - User forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: onMessageExchange and transform method

Posted by pradeep <pr...@gmail.com>.
Well I was looking into loan broker example. In the Bank class transform() is
used whereas in the LoanBroker onMessage() is used. Why is this. Sorry if
the question is stupid.


johper wrote:
> 
> Maybe you can tell a little bit more in detail what you would like to do?
> 
> 
> pradeep wrote:
>> 
>> I am new to Servicemix. I am confused between onMessageExchange and the
>> transform method. When I should  them ?thanks
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6205627
Sent from the ServiceMix - User forum at Nabble.com.


Re: onMessageExchange and transform method

Posted by johper <ka...@hotmail.com>.
Maybe you can tell a little bit more in detail what you would like to do?


pradeep wrote:
> 
> I am new to Servicemix. I am confused between onMessageExchange and the
> transform method. When I should  them ?thanks
> 

-- 
View this message in context: http://www.nabble.com/onMessageExchange-and-transform-method-tf2232002.html#a6191336
Sent from the ServiceMix - User forum at Nabble.com.