You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@curator.apache.org by GitBox <gi...@apache.org> on 2020/02/04 02:32:04 UTC

[GitHub] [curator] Randgalt commented on a change in pull request #344: CURATOR-558 - part 1 of ZK 3.6 updates

Randgalt commented on a change in pull request #344: CURATOR-558 - part 1 of ZK 3.6 updates
URL: https://github.com/apache/curator/pull/344#discussion_r374446608
 
 

 ##########
 File path: curator-recipes/src/test/java/org/apache/curator/framework/recipes/cache/TestTreeCache.java
 ##########
 @@ -423,9 +423,9 @@ public void testKilledSession() throws Exception
         client.create().withMode(CreateMode.EPHEMERAL).forPath("/test/me", "data".getBytes());
         assertEvent(TreeCacheEvent.Type.NODE_ADDED, "/test/me");
 
-        Compatibility.injectSessionExpiration(client.getZookeeperClient().getZooKeeper());
-        assertEvent(TreeCacheEvent.Type.NODE_REMOVED, "/test/me", "data".getBytes(), true);
+        client.getZookeeperClient().getZooKeeper().getTestable().injectSessionExpiration();
         assertEvent(TreeCacheEvent.Type.INITIALIZED, null, null, true);
+        assertEvent(TreeCacheEvent.Type.NODE_REMOVED, "/test/me", "data".getBytes(), true);
 
 Review comment:
   @cammckenzie I moved all kill session calls to use `zooKeeper.getTestable().injectSessionExpiration()`. When I did that, this particular test's message ordering changed. I didn't think it was too significant. Thoughts?

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


With regards,
Apache Git Services