We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Expected behaviour: When a coroutine inside mono { } fails with a TimeoutCancellationException, the returned Mono terminates with an error.
mono { }
TimeoutCancellationException
Mono
Actual behaviour: The returned Mono never completes.
Example:
import kotlinx.coroutines.delay import kotlinx.coroutines.reactor.mono import kotlinx.coroutines.withTimeout fun main() { val mono = mono { withTimeout(1) { delay(100) } } mono.doOnSubscribe { println("Subscribed") } .doOnNext { println("Emitted: $it") } .doOnSuccess { println("Completed") } .doOnError { println("Error: $it") } .doOnCancel { println("Cancelled") } .block() println("Done") }
The code above prints Subscribed and hangs forever.
Subscribed
It seems that such behaviour is introduced in #1638.
The text was updated successfully, but these errors were encountered:
f2f49b0
Complete mono { } on cancellation (Kotlin#2606)
cb682f5
Fixes Kotlin#2262
dkhalanskyjb
No branches or pull requests
Expected behaviour:
When a coroutine inside
mono { }
fails with aTimeoutCancellationException
, the returnedMono
terminates with an error.Actual behaviour:
The returned
Mono
never completes.Example:
The code above prints
Subscribed
and hangs forever.It seems that such behaviour is introduced in #1638.
The text was updated successfully, but these errors were encountered: