maedhroz commented on code in PR #1754:
URL: https://github.com/apache/cassandra/pull/1754#discussion_r931567701
##########
test/unit/org/apache/cassandra/db/KeyCacheTest.java:
##########
@@ -338,6 +340,24 @@ private void testKeyCache(String cf) throws
ExecutionException, InterruptedExcep
assertKeyCacheSize(noEarlyOpen ? 4 : 2, KEYSPACE1, cf);
}
+ @Test
+ public void testKeyCacheLoadZeroCacheLoadTimeBackwardCompatibility()
throws Exception
+ {
+ // Pre-4.1 users were asked to use negatives to disable. This test
validates the backward compatibility
+ // in case a user still uses their old yaml format and negative values
for this property.
+ DatabaseDescriptor.setCacheLoadTimeout(-1);
Review Comment:
...but doesn't `setCacheLoadTimeout()` here coerce the value to zero and, in
fact, not test `NEGATIVE_SECONDS_DURATION` w/ `cache_load_timeout_seconds`?
Seems like we'd want to reject negative values in `setCacheLoadTimeout()` but
test w/ something like `cassandra-old.yaml` where `cache_load_timeout_seconds:
-1` right?
--
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]