dcapwell commented on code in PR #2844:
URL: https://github.com/apache/cassandra/pull/2844#discussion_r1372138274
##########
src/java/org/apache/cassandra/repair/consistent/LocalSessions.java:
##########
@@ -637,10 +642,13 @@ public LocalSession getSession(TimeUUID sessionID)
}
@VisibleForTesting
- synchronized void putSessionUnsafe(LocalSession session)
+ synchronized boolean putSessionUnsafe(LocalSession session)
{
+ if (sessions.containsKey(session.sessionID))
Review Comment:
this actually makes it safe... but does have a big change in semantics...
for retry logic we need ability to dedup, so blind overriding can't be done...
I could always rename this to `putSession`....
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]