smiklosovic commented on code in PR #2215:
URL: https://github.com/apache/cassandra/pull/2215#discussion_r1138354892
##########
src/java/org/apache/cassandra/db/commitlog/CommitLog.java:
##########
@@ -177,7 +182,7 @@ public void recoverPath(String path) throws IOException
private static UUID getLocalHostId()
{
- return
Optional.ofNullable(StorageService.instance.getLocalHostUUID()).orElseGet(SystemKeyspace::getLocalHostId);
+ return StorageService.instance.getLocalHostUUID();
Review Comment:
if I understand that correctly, this will never be null anymore because we
are doing that initialization in `CassandraDaemon.`
##########
src/java/org/apache/cassandra/service/CassandraDaemon.java:
##########
@@ -236,6 +236,13 @@ protected void setup()
// This should be the first write to SystemKeyspace (CASSANDRA-11742)
SystemKeyspace.persistLocalMetadata();
+ // We should store host ID as soon as possible in the system.local
table and flush that table to disk so that
+ // we can be sure that those changes are stored in sstable and not in
the commit log (see CASSANDRA-18153).
Review Comment:
sstable -> SSTable
--
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]