Hi Lars,
thanks for the quick answer.
We are using
deliverChannel.sendSync(myExchange);
for sending our exchanges.
We also thought that there is a timing problem, but how can we solve this?
We are routing the whole request, because we need all information on the other
bean. And after the bean added some information to the request and processed
some work on the given information, the service will do some additional work on
the data.
The first bean acts as an dispatcher and routes the data to another bean, later
on there will be other endpoints as well to which the data can be routed,
depending on which information are in the data.
We choose to use a bean-component as a dispatcher and not camel, because we
know the bean-component and thought this will be straight forward and won't
take much time, since we experienced some problems whenever we try to use a new
component.
@Gerd: in OUR exchanges we use StringSource but since we take the msg from the
jsr181 and route it through, it could be the problem if the jsr181 uses e.g.:
StreamSource.
Regards,
Jens
Sitz der Gesellschaft / Corporate Headquarters:
Lufthansa Systems AS GmbH, Norderstedt
Registereintragung / Registration:
Amtsgericht Norderstedt 3688NO
Geschaeftsfuehrung/ Management:
Bernd Appel
-----Ursprüngliche Nachricht-----
Von: Lars Heinemann [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 6. Juni 2008 12:44
An: [email protected]
Betreff: Re: MessageExchange content empty with 2 beans
Jens,
are you sure, that these exchanges are sent with sendSync in any case?
For me it sounds somehow like a timing problem. When switching to DEBUG log
level, the processing will take much longer time as more outputs are logged
than in the WARN log level.
Another question is, why do you route the whole soap request to other beans? I
mean in your JSR181 SU you could just create a message exchange, put all
needed variables from the soap call into the normalized message and send it
sync to the other beans.
Regards,
Lars
On Friday 06 June 2008 12:23:03 [EMAIL PROTECTED] wrote:
> Hi everybody,
>
> We are using a jsr181 service for retrieving soap requests.
> In the service we call the JBIContext.getMessageExchange() method to
> retrieve the actual Exchange.
> Then we send (using sendSync) the InMsg of the Exchange to a bean. The
> bean routes (sendSync) it to another bean.
> When all the work is done and we are back in the jsr181 service we do
> some additional work before we return the response to the sender.
>
> The second bean was added a few days ago. Before that everything worked
> fine. Now with the second been we have a problem:
> The content of every exchange is empty. The InMsg is not null but only
> <?xml ...?> without the actual request data. This starts at the service
> when we log the exchange we got from the JBIContext.getMessageExchange()
> method.
>
> Now comes the tricky part. When we switch the log-level from WARN to
> DEBUG everything works fine! How is this possible?
> Has it something to do with SM-1171 ?
>
> Here are a some information about the usage of the bean-component:
>
> The deployment descriptor for both beans looks similar to this <?xml
> version="1.0" encoding="UTF-8"?> <beans
> xmlns:bean="http://servicemix.apache.org/bean/1.0"
> xmlns:hello="urn:world">
>
> <bean:endpoint service="hello:service" endpoint="endpoint"
> bean="#aBean"/>
>
> <bean id="aBean" class="hello.world.Bean"/> </beans>
>
> The Beans are implementing the MessageExchangeListener, the Context and
> DeliveryChannel are injected by annotations ( @Resource )
>
>
> The flow is like this: (all Exchanges are InOut)
>
> Exchange1 Exchange2 Exchange3 Exchange3 Exchange2
> Exchange1
> In In In Out Out
> Out
> Client => aService => aBean1 => aBean2 => aBean1 => aService
> => Client
>
> We are using servicemix version 3.2.1
>
> Please Help!
>
>
>
>
>
> Sitz der Gesellschaft / Corporate Headquarters:
> Lufthansa Systems AS GmbH, Norderstedt
> Registereintragung / Registration:
> Amtsgericht Norderstedt 3688NO
>
> Geschaeftsfuehrung/ Management:
> Bernd Appel