-
Notifications
You must be signed in to change notification settings - Fork 556
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
10018: Try to handle expected error in record processor r=korthout a=korthout ## Description <!-- Please explain the changes you made here. --> This PR offers a solution for - #9420 The idea is to pass the error to the specific `TypedRecordProcessor`, which can decide whether the error is `EXPECTED` or `UNEXPECTED`. - If the error is `UNEXPECTED`, we handle it as before by writing an Error event, etc. - If the error is `EXPECTED`, we let the processor control how we reject the command and what else has to happen. This PR shows how this could work by also providing a solution for - #9644 A test is added to verify the correct behavior: custom rejection + transaction rolled back. The test showed that a hidden bug was introduced (I managed to bisect this to 463366f): the output was reset on error, but no longer when encapsulated by the ProcessingResultBuilder. A fix for this bug is also part of this PR. ## Related issues <!-- Which issues are closed by this PR or are related --> closes #9420 closes #9644 Co-authored-by: Nico Korthout <nico.korthout@camunda.com>
- Loading branch information
Showing
8 changed files
with
153 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters