How do I support cancellation of kotlin coroutines on connection close for all REST requests #41696
Replies: 2 comments 9 replies
-
/cc @geoand (kotlin) |
Beta Was this translation helpful? Give feedback.
8 replies
-
This is confirmed to be working in 3.13.0.CR1. Thanks @geoand |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I just started testing out Quarkus with Kotlin suspend handlers and it seems to work well. However, I noticed that these handlers don't support cancellation on request connection closing. I found a workaround, but it seems very cumbersome and would like to find out if there's a better way.
In the sample code below, endpoint
/long/a
cancels the delay by throwing theCancellationException
when the connection is closed, but/long/b
does not.Beta Was this translation helpful? Give feedback.
All reactions