maedhroz commented on a change in pull request #1204:
URL: https://github.com/apache/cassandra/pull/1204#discussion_r743224834
##########
File path: src/java/org/apache/cassandra/auth/AuthCache.java
##########
@@ -212,6 +277,20 @@ public int getMaxEntries()
return getMaxEntriesDelegate.getAsInt();
}
+ public boolean getActiveUpdate()
+ {
+ return getActiveUpdate.getAsBoolean();
+ }
+
+ public void setActiveUpdate(boolean update)
+ {
+ if
(Boolean.getBoolean("cassandra.disable_auth_caches_remote_configuration"))
+ throw new UnsupportedOperationException("Remote configuration of
auth caches is disabled");
+
+ setActiveUpdate.accept(update);
+ cache = initCache(cache);
Review comment:
nit: This is also happening above in `setMaxEntries()`, but the
assignment and the call to `initCache()` together constitute a check-and-set
operation. Throwing a `synchronized` on `setActiveUpdate()` and
`setMaxEntries()` would at least make the static analysis tools happy.
--
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]