Hello all,
my colleague Matthias Koch and I have some request regarding the Microprofile-LRA-Spec, related to my question 4.3 you answered here:
- Is there a way for the compensation method to find out, if it was called because of a timeout or any other error?
No the spec just defines
the triggers to guarantee atomic outcomes (but we can add it if you
think that is something applications would find useful).
Yes, we would find it rather useful. Please add it.
To summarize:
GIVEN: a LRA is being called that is running into a timeout (a timeLimit for the LRA is set).
THEN: The compensatory actions of the participants are triggered. But there is the possibility that LRA actually succeeds, although there was a timeout.
REQUEST: Since we can not identify if the LRA is being cancelled because of a timeout or an error, we have to call the @Status method to detect if the LRA is still running, was successful, or did indeed fail.
(or - if there is no @Status method, the idempotent @Compensate method). This appears to be rather clumsy.
We would feel better if the participants could easily identify in the compensation method if there reason for the trigger was a timeout or not, so unnecessary calls to the LRA are avoided.
Best regards,
Max Grabert