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 2020/08/18 18:13:37 UTC

[GitHub] [beam] nehsyc commented on a change in pull request #12578: [BEAM-10703] Prepare Dataflow Java runner for shardable states

nehsyc commented on a change in pull request #12578:
URL: https://github.com/apache/beam/pull/12578#discussion_r472389332



##########
File path: runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/StreamingModeExecutionContext.java
##########
@@ -357,7 +358,7 @@ public void invalidateCache() {
         }
       }
       activeReader = null;
-      stateCache.invalidate(key);
+      stateCache.invalidate(key, getWork().getShardingKey());

Review comment:
       Good catch! Fixed.

##########
File path: runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/StreamingDataflowWorker.java
##########
@@ -2193,7 +2235,7 @@ public boolean activateWork(ByteString key, Work work) {
     }
 
     /** Marks the work for a the given key as complete. Schedules queued work for the key if any. */
-    public void completeWork(ByteString key, long workToken) {
+    public void completeWork(ShardedKey key, long workToken) {

Review comment:
       Done

##########
File path: runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/StreamingDataflowWorker.java
##########
@@ -2167,7 +2209,7 @@ public MapTask getMapTask() {
     }
 
     /** Mark the given key and work as active. */
-    public boolean activateWork(ByteString key, Work work) {
+    public boolean activateWork(ShardedKey key, Work work) {

Review comment:
       Done.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org