tephra-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From poornachandra <...@git.apache.org>
Subject [GitHub] incubator-tephra pull request #8: Fix flaky test (PooledClientProviderTest)
Date Fri, 09 Sep 2016 07:12:05 GMT
Github user poornachandra commented on a diff in the pull request:

    https://github.com/apache/incubator-tephra/pull/8#discussion_r78137456
  
    --- Diff: tephra-core/src/test/java/org/apache/tephra/distributed/PooledClientProviderTest.java
---
    @@ -137,15 +137,15 @@ public Boolean call() throws Exception {
     
     
         //Now race to get MAX_CLIENT_COUNT+1 clients, exhausting the pool and requesting
1 more.
    -    List<Future<Integer>> clientIds = new ArrayList<Future<Integer>>();
    -    CountDownLatch countDownLatch = new CountDownLatch(1);
    +    List<Future<Integer>> clientIds = new ArrayList<>();
    +    // we want to ensure that all clients have been exhausted before releasing any
    +    CountDownLatch countDownLatch = new CountDownLatch(MAX_CLIENT_COUNT);
    --- End diff --
    
    Would be good to call this `clientDoneLatch`


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message