You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2022/03/02 19:06:58 UTC
[GitHub] [beam] scwhittle commented on a change in pull request #16992: Make ScopedReadStateSupplier final
scwhittle commented on a change in pull request #16992:
URL: https://github.com/apache/beam/pull/16992#discussion_r818010542
##########
File path: runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/StreamingModeExecutionContext.java
##########
@@ -481,6 +481,25 @@ String getStateFamily(NameContext nameContext) {
return nameContext.userName() == null ? null : stateNameMap.get(nameContext.userName());
}
+ private static class ScopedReadStateSupplier implements Supplier<Closeable> {
+ private final ExecutionState readState;
+ private final @Nullable ExecutionStateTracker stateTracker;
+
+ ScopedReadStateSupplier(
+ DataflowOperationContext operationContext, ExecutionStateTracker stateTracker) {
+ this.readState = operationContext.newExecutionState("windmill-read");
Review comment:
nit: only do this if stateTracker is non-null?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org