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
Ability to specify a limited dispatcher name #4023
Labels
Comments
I'm concerned that |
5 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Use case
We have specific dispatchers, and in coroutine dumps they all look like
LimitedDispatcher@xxxxxxxx
, and it's not immediately clear where the dispatcher comes from.The Shape of the API
Make
kotlinx.coroutines.CoroutineDispatcher.limitedParallelism
acceptdebugName: String?
.Alternatively, make an extension function
fun CoroutineDispatcher.namedDispatcher(debugName: String): CoroutineDispatcher
which will return a dispatcher, which delegates tothis
and has itstoString
overridden. It can returnthis
as is when debug is off.Prior Art
kotlinx.coroutines.scheduling.LimitingDispatcher
hasname
.The text was updated successfully, but these errors were encountered: