keith-turner commented on code in PR #5008:
URL: https://github.com/apache/accumulo/pull/5008#discussion_r1812939681


##########
core/src/main/java/org/apache/accumulo/core/clientImpl/ZookeeperLockChecker.java:
##########
@@ -59,11 +59,8 @@ public boolean isLockHeld(String server, String session) {
 
   @Override
   public void invalidateCache(String tserver) {
-    var hostAndPort = HostAndPort.fromString(tserver);
-    ctx.getServerPaths().getTabletServer(rg -> true, 
AddressSelector.exact(hostAndPort), false)
-        .forEach(slp -> {
-          ctx.getZooCache().clear(slp.toString());
-        });
+    // The path for the tserver contains a resource group. The resource group 
is unknown, so can not
+    // construct a prefix. Therefore clear any path that contains the tserver.
+    ctx.getZooCache().clear(path -> path.contains(tserver));

Review Comment:
   Definitely want to avoid overmatching as that could cause performance 
problems.  Will make this change before merging.



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

Reply via email to