[ https://issues.apache.org/jira/browse/BEAM-5709?focusedWorklogId=153303&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-153303 ]
ASF GitHub Bot logged work on BEAM-5709: ---------------------------------------- Author: ASF GitHub Bot Created on: 10/Oct/18 22:23 Start Date: 10/Oct/18 22:23 Worklog Time Spent: 10m Work Description: youngoli commented on a change in pull request #6639: [BEAM-5709] Fix flaky tests in BeamFnControlServiceTest. URL: https://github.com/apache/beam/pull/6639#discussion_r224261195 ########## File path: runners/google-cloud-dataflow-java/worker/src/test/java/org/apache/beam/runners/dataflow/worker/fn/BeamFnControlServiceTest.java ########## @@ -88,6 +88,8 @@ public void testClientConnecting() throws Exception { server.shutdown(); server.awaitTermination(1, TimeUnit.SECONDS); server.shutdownNow(); + Thread.sleep(1000); // Wait for stub to close stream. Review comment: That sounds like a good idea. I'm assuming with that method some kind of timeout would be set on the latch, so that if onCompleted doesn't get called in a certain timespan we can fail the test? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 153303) Time Spent: 1h (was: 50m) > Tests in BeamFnControlServiceTest are flaky. > -------------------------------------------- > > Key: BEAM-5709 > URL: https://issues.apache.org/jira/browse/BEAM-5709 > Project: Beam > Issue Type: Bug > Components: runner-dataflow > Reporter: Daniel Oliveira > Assignee: Daniel Oliveira > Priority: Minor > Time Spent: 1h > Remaining Estimate: 0h > > https://github.com/apache/beam/blob/master/runners/google-cloud-dataflow-java/worker/src/test/java/org/apache/beam/runners/dataflow/worker/fn/BeamFnControlServiceTest.java > Tests for BeamFnControlService are currently flaky. The test attempts to > verify that onCompleted was called on the mock streams, but that function > gets called on a separate thread, so occasionally the function will not have > been called yet, despite the server being shut down. -- This message was sent by Atlassian JIRA (v7.6.3#76005)