Add blocking runtime from upstream quickwit-oss #3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR add the ability to select a blocking runtime via
Actor::runtime_handle
as implemented in https://github.com/quickwit-oss/quickwit/blob/926c0f7650b2369c44922ddb6d387aa194b42aee/quickwit/quickwit-common/src/runtimes.rs#L112I made a little change to the original implementation to simplify feature selection (between test runtime and non test runtime).
Also I am not sure but I think this should be
spawn_blocking
whenRuntimeType::Blocking
is used.https://github.com/guilload/witty-actors/blob/25b3df45848b2e6670a2ce874bee6c8a2a8e93ef/src/spawn_builder.rs#L167
Either I am missing something or using ``RunType::TypeBlocking` does nothing except controlling the number of worker_thread on the tokio runtime.
Can you clarify on this ?