I'm currently working on a SOA project.
I have to develop several processing chains, that is to say a web-services that chain web-services inside an ESB in Java.
Since every web-service to chain can throw different exception, I thought about using Transactions to be able to rollback the web-services behaviors.
However, I have no idea if this is even possible in an SOA environnement when every service is different. I searched it and found some information about AtomicTransactions but I'm not sure it's can be used to solve my problem.
To conclude, my questions are is it actually possible to rollback services? And if so, how can I set it up?
Thanks in advance.
Using transactions between services is not a good practice as you're holding up resources for components that are not necessarily trustworthy, plus service processes are usually long-running (I wrote about it more in "transactional-integration anti-pattern".
As someone mentioned in a comment I find that the "saga pattern" is a better way to handle these long running interactions
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With