keith-turner commented on code in PR #5417:
URL: https://github.com/apache/accumulo/pull/5417#discussion_r2003573464
##########
core/src/main/java/org/apache/accumulo/core/clientImpl/ConditionalWriterImpl.java:
##########
@@ -683,7 +682,7 @@ private void invalidateSession(SessionID sessionId,
HostAndPort location)
long startTime = System.currentTimeMillis();
- LockID lid = new LockID(Constants.ZTSERVERS, sessionId.lockId);
+ LockID lid = LockID.deserialize(sessionId.lockId);
Review Comment:
This code was only used by the conditional writer client side in failure
cases. The server side would substract the tservers prefix and client would
add it back to check if tserver was still alive. This particular case was
really dangerous on the tserver side because it was a tserver instance variable
w/ different prefix behavior than all other lock checking code, so if anything
else used this tserver variable it could have easily gotten it wrong. On the
tserver side it uses a LockId var instead of a string now for the instance
variable.
--
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]