You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Caranthir <ca...@gmail.com> on 2017/05/30 11:23:01 UTC

Difference between WireTap and to

Hello,

I have a problem. In my camel application I have two JPA endpoints. Where I
get some values from one database and insert it to the other one. 

So I defined jpa endpoint for one database and jpa2 for the other database. 

i get some value with 
from(jpa://...).process( ... ).to(direct:e)

then 
from(direct:e).process( ... ).to(jpa2:// ...).to(direct:d)
then

from(direct:d).to(jpa://..)

When I do this the last insert to the jpa component doesnt work as expected
and tries to insert to jpa2 instead of jpa. I was pretty confused. 

It took a few days to resolve this issue.

When I only changed to value to WireTap, it started working as expected and
inserted values to jpa .

from(jpa://...).process( ... ).to(direct:e)

then 
from(direct:e).process( ... ).to(jpa2:// ...).wireTap(direct:d)
then

from(direct:d).to(jpa://..)


Is there a difference between to(direct:d) and wireTap(direct:d) that is not
clear to me?

Thanks




--
View this message in context: http://camel.465427.n5.nabble.com/Difference-between-WireTap-and-to-tp5801360.html
Sent from the Camel - Users mailing list archive at Nabble.com.

AW: Difference between WireTap and to

Posted by Burkard Stephan <St...@visana.ch>.
Hi 

difference between to and wiretap: Wiretap uses a dedicated thread pool to process the messages. So you have to be careful about transaction boundaries. 

Regards
Stephan


-----Ursprüngliche Nachricht-----
Von: Caranthir [mailto:candelorman@gmail.com] 
Gesendet: Dienstag, 30. Mai 2017 13:23
An: users@camel.apache.org
Betreff: Difference between WireTap and to

Hello,

I have a problem. In my camel application I have two JPA endpoints. Where I get some values from one database and insert it to the other one. 

So I defined jpa endpoint for one database and jpa2 for the other database. 

i get some value with
from(jpa://...).process( ... ).to(direct:e)

then
from(direct:e).process( ... ).to(jpa2:// ...).to(direct:d) then

from(direct:d).to(jpa://..)

When I do this the last insert to the jpa component doesnt work as expected and tries to insert to jpa2 instead of jpa. I was pretty confused. 

It took a few days to resolve this issue.

When I only changed to value to WireTap, it started working as expected and inserted values to jpa .

from(jpa://...).process( ... ).to(direct:e)

then
from(direct:e).process( ... ).to(jpa2:// ...).wireTap(direct:d) then

from(direct:d).to(jpa://..)


Is there a difference between to(direct:d) and wireTap(direct:d) that is not clear to me?

Thanks




--
View this message in context: http://camel.465427.n5.nabble.com/Difference-between-WireTap-and-to-tp5801360.html
Sent from the Camel - Users mailing list archive at Nabble.com.