Skip to content

GH-3618: Support CommonErrorHandler for suspend functions#4254

Open
zooo-code wants to merge 1 commit intospring-projects:mainfrom
zooo-code:GH-3618
Open

GH-3618: Support CommonErrorHandler for suspend functions#4254
zooo-code wants to merge 1 commit intospring-projects:mainfrom
zooo-code:GH-3618

Conversation

@zooo-code
Copy link

Fixes GH-3618(#3618)

Summary

Support CommonErrorHandler (e.g., DefaultErrorHandler) for Kotlin suspend functions.

Previously, exceptions from suspend functions were only logged and not propagated to CommonErrorHandler. This change sets up the async failure callback for RecordMessagingMessageListenerAdapter when CommonErrorHandler is explicitly configured.

Changes

  • Setup async failure callback when CommonErrorHandler is explicitly configured
  • Add test for suspend function with CommonErrorHandler in EnableKafkaKotlinCoroutinesTests.kt

Related

Thanks!!

Please let me know if any changes are needed. I'm happy to address any feedback promptly.

Fixes spring-projectsGH-3618(spring-projects#3618)

* Setup async failure callback when CommonErrorHandler is explicitly configured
* Add test for suspend function with CommonErrorHandler

Signed-off-by: zoo-code <kyj20908@naver.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DefaultErrorHandler doesn't work with suspend methods

2 participants