scalar-labs/btm

Issues related to spring cloud + feign

ice-ice opened this issue · 3 comments

call chain :

serverA -> serverB

serverA method describtion:

Execute the local transaction first.(insert data into db.)
and use feign to call remote serverB.
next , throw RunTimeException();

serverB method describtion:
Only Execute the local transaction.
insert data into db.

now.......

serverB is Insert the success .
serverA is insert failure...because serverA throw RunTimeException;


so ............

serverB Should be rolled back !!!!

but serverB insert success ??????? WHY ????

pay special attention to
serverA 。

call serverB ,first..
next , throw RunTimeException()

Notice the order of execution ..........

plz tell me why ................. What should I do

serverA :

serverB:

BTM does not implement anything that would make transactions propagate across servers. I don't think there's ever been a protocol to do that over REST (like WS-AT does for SOAP).

In short: this isn't supported and cannot work.