Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement CommonErrorHandler.handleOne() in CommonDelegatingErrorHandler #3227

Closed
Blackney opened this issue May 3, 2024 · 1 comment
Closed

Comments

@Blackney
Copy link
Contributor

Blackney commented May 3, 2024

Expected Behavior

CommonDelegatingErrorHandler should implement CommonErrorHandler.handleOne()
This implementation should be the same as the other handle methods - Finding a delegate CommonErrorHandler, then call it's .handleOne() method. If a delegate cannot be found, use the defaultErrorHandler

Current Behavior

Currently this method is not implemented, and the default behaviour from the CommonErrorHandler interface is to log an error and return true, indicating the error was "handled"

Context

This issue came up when trying to use the DefaultErrorHandler with seekAfterError set to false
The value of seekAfterError is used for the return of the DefaultErrorHandler.seeksAfterHandling() method, the value of which is used to decide whether CommonErrorHandler.handleRemaining() vs CommonErrorHandler.handleRemaining() is called when an error is thrown by a non-batch Listener

I wish to be able to use the seekAfterError behaviour in the DefaultErrorHandler, while also using the CommonDelegatingErrorHandler to delegate between different DefaultErrorHandler's

spring-builds pushed a commit that referenced this issue May 3, 2024
Fixes: #3227

* Implement handleOne() in `CommonDelegatingErrorHandler`
* Add tests for handle methods in `CommonDelegatingErrorHandler`
* Add tests for the new `handleOne()` method, as well as a test for `handleOtherException()`
* Checkstyle fixes

(cherry picked from commit 4e06c2c)
sobychacko pushed a commit that referenced this issue May 3, 2024
Fixes: #3227

* Implement handleOne() in `CommonDelegatingErrorHandler`
* Add tests for handle methods in `CommonDelegatingErrorHandler`
* Add tests for the new `handleOne()` method, as well as a test for `handleOtherException()`
* Checkstyle fixes

(cherry picked from commit 4e06c2c)
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants