dcapwell commented on code in PR #2295:
URL: https://github.com/apache/cassandra/pull/2295#discussion_r1178236629
##########
src/java/org/apache/cassandra/config/Config.java:
##########
@@ -359,9 +352,14 @@ public MemtableOptions()
public String[] data_file_directories = new String[0];
- public List<ParameterizedClass> sstable_formats = ImmutableList.of(new
ParameterizedClass(BigFormat.class.getName(),//
"org.apache.cassandra.io.sstable.format.big.BigFormat",
-
ImmutableMap.of(SSTABLE_FORMAT_ID, "0",
-
SSTABLE_FORMAT_NAME, "big")));
+ public static class SSTableFormats
+ {
+ public String selected_format;
+ public String selected_version;
Review Comment:
> this should always be changed together
agree, but we would need locking or copy-on-write configs to support that,
which we don't have in this patch (and not arguing we add). This means a
config change happens each time a field is modified, which could put us in a
inconsistence state waiting for the operator to update the other fields.
So, by having the version in `options` this at least scopes things to where
they make sense... if you are using `big` and want to test out `bti v42` you
can update the configs for `bti.version=42`, this would have no runtime impact
as its untouched. But let's say you are using `bti v41` and want to switch to
`v42`? you then do `bit.version=42` and the next sstable uses `v42`. By
having the version in the options it makes the concurrency easier to reason
about
--
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]