-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
[Dataflow Streaming] Optimizing work submit loop #33736
Conversation
@@ -88,7 +87,7 @@ private Work( | |||
this.watermarks = watermarks; | |||
this.clock = clock; | |||
this.startTime = clock.get(); | |||
this.totalDurationPerState = new EnumMap<>(LatencyAttribution.State.class); | |||
this.totalDurationPerState = new HashMap<>(); |
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.
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.
Another idea where the map would still be stored as an array without hashing is to have an empty static EnumMap that you construct the new map referencing. Then it wouldn't have to recalculate the key universe
R: @scwhittle |
Stopping reviewer notifications for this pull request: review requested by someone other than the bot, ceding control. If you'd like to restart, comment |
Run Java PreCommit |
1 similar comment
Run Java PreCommit |
...org/apache/beam/runners/dataflow/worker/windmill/work/processing/StreamingWorkScheduler.java
Outdated
Show resolved
Hide resolved
@@ -88,7 +87,7 @@ private Work( | |||
this.watermarks = watermarks; | |||
this.clock = clock; | |||
this.startTime = clock.get(); | |||
this.totalDurationPerState = new EnumMap<>(LatencyAttribution.State.class); | |||
this.totalDurationPerState = new HashMap<>(); |
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.
Another idea where the map would still be stored as an array without hashing is to have an empty static EnumMap that you construct the new map referencing. Then it wouldn't have to recalculate the key universe
...src/main/java/org/apache/beam/runners/dataflow/worker/util/common/worker/OutputReceiver.java
Show resolved
Hide resolved
Done. |
failure appears unrelated |
#33578