MINOR improve startup log in QuorumController (#15926)

Reviewers: David Arthur <mumrah@gmail.com>
This commit is contained in:
ChickenchickenLove 2024-06-18 00:04:12 +09:00 committed by GitHub
parent 92d8d4bd1f
commit 1a7ba667ad
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 2 deletions

View File

@ -165,6 +165,7 @@ public class ActivationRecordsGenerator {
throw new RuntimeException("Should not have ZK migrations enabled on a cluster that was " +
"created in KRaft mode.");
}
logMessageBuilder.append("This is expected because this is a de-novo KRaft cluster.");
break;
case PRE_MIGRATION:
if (!metadataVersion.isMetadataTransactionSupported()) {

View File

@ -192,7 +192,8 @@ public class ActivationRecordsGeneratorTest {
assertEquals(0, result.records().size());
result = ActivationRecordsGenerator.recordsForNonEmptyLog(
logMsg -> assertEquals("Performing controller activation. Loaded ZK migration state of NONE.", logMsg),
logMsg -> assertEquals("Performing controller activation. Loaded ZK migration state of NONE. "
+ "This is expected because this is a de-novo KRaft cluster.", logMsg),
-1L,
false,
buildFeatureControl(MetadataVersion.IBP_3_4_IV0, Optional.empty()),
@ -203,7 +204,8 @@ public class ActivationRecordsGeneratorTest {
result = ActivationRecordsGenerator.recordsForNonEmptyLog(
logMsg -> assertEquals("Performing controller activation. Aborting in-progress metadata " +
"transaction at offset 42. Loaded ZK migration state of NONE.", logMsg),
"transaction at offset 42. Loaded ZK migration state of NONE. " +
"This is expected because this is a de-novo KRaft cluster.", logMsg),
42L,
false,
buildFeatureControl(MetadataVersion.IBP_3_6_IV1, Optional.empty()),