1: Could the from-endpoint decide how to do the post-action  according to
following  route's transaction result(rollback/commit)?

 Fo example :
        from().transacted().multicast().db1().db2();

        from() will receive a external message. Db1, db2 will insert the
message to different database; and a jta-transaction is controlling the two
database resource.
        Now we wish the (from) external system's message will be delete only
when the both database operation succeed. If one of it failed, the other
database will rollback, and the (from) external system's message will also
be reserved;
        If the the (from) external system is a transactional-resource, etc:
jms or database, there will no problem;
        But if the (from) external system is file(or some other, etc: email,
ftp), could the camel's file component can delete or reserve the file
according to the result of jta-transaction?

2) When using multi jta transaction in one exchange, it must be separate to
different route using direct-endpoint; But if so, when transactions  is
nested; and inner's exception occurs,how does the outer transaction deal
with the exception? Outer transaction will ignore the exception and commit,
or treat it as exception and rollback?

 let's take a example:
        {a,{b,c}d}
The route has 4 processor, now [a,.. ,d] belong to a jta transaction, [b-c]
belong to a new jta  transaction; 
Camel will ask for configure it as two route:
        From().transacted(required).a().to("direct:x").d();
        From("direct:x").transacted().b().c();

So if b or c raise exception in the inner transaction's route, how does the
outer transaction do? Rollback or commit ?


3)  If I using multi transaction in one exchange , must I separate the it to
diff route using direct-endpoint?
        ...actually, I find a un-document ways to use the multi camel
transaction, which need not separate route . That's just configure the
camel's transaction as a policy.
 
        A few month ago, I have ask the question. And the answer is the
camel's 2.1 doesn't support configured policy. But now camel's 2.5 is
published, could it support such a usage?



Reply via email to