News for hackers. Stuff that matters.
Re:Best Practices for Testing in Java (2019) by exabrial on Wednesday September 02, 2020 @08:43AM (#24352633)
Correct. A business logic controller can not directly corner the outside world, it must talk through a service.

This is nice because it prevents leaky abstractions into the controller layer. Actions across services that need to be atomic can be grouped in an XA transaction:

// Xa start databaseService.reset password(user); emailService.notifyPasswordChange(user); // Xa commit

There are no comments on this comment yet.