-
Notifications
You must be signed in to change notification settings - Fork 106
Use WorkStealingDispatcher in runtime, behind a flag. #1365
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
base: zachklipp/dispatcher
Are you sure you want to change the base?
Use WorkStealingDispatcher in runtime, behind a flag. #1365
Conversation
So if this works, use it instead of adding the new Compose dependency? |
4df1469
to
b71978b
Compare
65a8c7f
to
c150bc0
Compare
5adab40
to
b81c18d
Compare
9c0f379
to
26aab12
Compare
b81c18d
to
484d9c5
Compare
a2fe965
to
ab23b7b
Compare
e06b394
to
20e7b6b
Compare
f6e81e9
to
468cef1
Compare
I would still like to get away from Unconfined if there's an opportunity to do so, but if this lets us move faster without shaving that yak, then awesome. |
Changed to draft while I write tests. |
c652b31
to
2547ad1
Compare
20e7b6b
to
e56709d
Compare
2547ad1
to
68c7b69
Compare
@@ -161,6 +169,8 @@ public enum class RuntimeConfigOptions { | |||
// DRAIN_EXCLUSIVE_ACTIONS, | |||
// ) | |||
// ), | |||
|
|||
ALL(RuntimeConfigOptions.entries.toSet()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems to me like it would be a good idea to have a config that turns on all the flags (for testing, but also for green-field uses of the runtime), but if you'd rather I add explicit configs for this new flag I can do that too.
@@ -1494,7 +1501,9 @@ class RenderWorkflowInTest( | |||
|
|||
@Test | |||
fun for_conflate_we_do_not_conflate_stacked_actions_into_one_rendering_if_output() { | |||
if (runtimeConfig.contains(CONFLATE_STALE_RENDERINGS)) { | |||
if (CONFLATE_STALE_RENDERINGS in runtimeConfig && | |||
WORK_STEALING_DISPATCHER !in runtimeConfig |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This tested behavior intentionally changes with WSD on.
I added a single test for the new ordering behavior. I don't know if we need more than that since |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I realize the latest version of it is not merged yet - but where I would really like to test this is with the tests in AndroidDispatchersRenderWorkflowInTest
workflow-runtime-android/src/androidTest/java/com/squareup/workflow1/android/AndroidDispatchersRenderWorkflowInTest.kt
Currently in the branch from this PR - #1355
We could merge your WSD and then I could rebase and test it with that I guess?
d606d8c
to
483cca7
Compare
c660617
to
446b1d8
Compare
Installs the
WorkStealingDispatcher
introduced in #1364 into the workflow runtime behind a new runtime flag.