arunpandianp commented on code in PR #39961:
URL: https://github.com/apache/beam/pull/39961#discussion_r4045640366
##########
runners/google-cloud-dataflow-java/worker/src/test/java/org/apache/beam/runners/dataflow/worker/StreamingModeExecutionContextTest.java:
##########
@@ -497,9 +498,9 @@ public void testSetBacklogBytes() {
stepContext.setBacklogBytes(1234.0);
executionContext.finishKey();
- executionContext.flushState();
+ ExecuteWorkResult result = executionContext.flushStateAndReset();
- assertEquals(1234,
executionContext.getOutputBuilder().getSourceBacklogBytes());
+ assertEquals(1234,
result.workItemCommits().get(0).getSourceBacklogBytes());
Review Comment:
done.
##########
runners/google-cloud-dataflow-java/worker/src/test/java/org/apache/beam/runners/dataflow/worker/WorkerCustomSourcesTest.java:
##########
@@ -706,21 +708,20 @@ public void testReadUnboundedReader() throws Exception {
numReadOnThisIteration,
lessThanOrEqualTo(debugOptions.getUnboundedReaderMaxElements()));
// Extract and verify state modifications.
- context.flushState();
- state = context.getOutputBuilder().getSourceStateUpdates().getState();
+ context.finishKey();
+ WindmillComputationKey computationKey = context.getComputationKey();
+ ExecuteWorkResult result = context.flushStateAndReset();
+ Windmill.WorkItemCommitRequest commitRequest =
result.workItemCommits().get(0);
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]