From 3229970566ec41c468e4eaa60d89657b84cff2c3 Mon Sep 17 00:00:00 2001
From: ZhangJian He <header><index pages>
- * Header is formated as below:
+ * Header is formatted as below:
* <magic bytes><len of master key><master key>
*
*
- * Index page is a fixed-length page, which contains serveral entries which point to the offsets of data stored
+ * Index page is a fixed-length page, which contains several entries which point to the offsets of data stored
* in entry loggers.
*
It would try to load the class with the constructor with hostRegionOverrides
.
* If it fails, it would fall back to load the class with default empty constructor.
- * The interpretion of hostRegionOverrides
is up to the implementation.
+ * The interpretation of hostRegionOverrides
is up to the implementation.
*
* @param resolverCls
* resolver class
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAppendOnlyStreamWriter.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAppendOnlyStreamWriter.java
index 0608bd6bc4a..2c8f2f7443d 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAppendOnlyStreamWriter.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAppendOnlyStreamWriter.java
@@ -296,7 +296,7 @@ long writeRecordsAndReadThemBackAfterInjectingAFailedTransmit(
FailpointUtils.FailPointActions.FailPointAction_Throw);
writer.force(false);
- fail("should have thown ⊙﹏⊙");
+ fail("should have thrown ⊙﹏⊙");
} catch (WriteException we) {
} finally {
FailpointUtils.removeFailpoint(
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderLock.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderLock.java
index a4ceea79af3..94d4cf6014f 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderLock.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderLock.java
@@ -277,7 +277,7 @@ public void testReaderLockSessionExpires() throws Exception {
ns1.getNamespaceDriver()).getWriterZKC(), zkServers, 1000);
// The result of expireSession is somewhat non-deterministic with this lock.
- // It may fail with LockingException or it may succesfully reacquire, so for
+ // It may fail with LockingException or it may successfully reacquire, so for
// the moment rather than make it deterministic we accept either result.
boolean success = false;
try {
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKDistributedLogManager.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKDistributedLogManager.java
index 9341dece0b6..dcc422e7861 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKDistributedLogManager.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKDistributedLogManager.java
@@ -335,7 +335,7 @@ public void testWriteRestartFrom1() throws Exception {
}
out.closeAndComplete();
- // open journal arbitarily far in the future
+ // open journal arbitrarily far in the future
txid = DEFAULT_SEGMENT_SIZE * 4;
out = (BKSyncLogWriter) dlm.startLogSegmentNonPartitioned();
out.write(DLMTestUtil.getLogRecordInstance(txid));
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKLogSegmentWriter.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKLogSegmentWriter.java
index 89aab53e07c..80abd934113 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKLogSegmentWriter.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestBKLogSegmentWriter.java
@@ -263,9 +263,9 @@ public void testCloseShouldFlush() throws Exception {
numRecords, dlsns.size());
for (int i = 0; i < numRecords; i++) {
DLSN dlsn = dlsns.get(i);
- assertEquals("Incorrent ledger sequence number",
+ assertEquals("Incorrect ledger sequence number",
0L, dlsn.getLogSegmentSequenceNo());
- assertEquals("Incorrent entry id",
+ assertEquals("Incorrect entry id",
0L, dlsn.getEntryId());
assertEquals("Inconsistent slot id",
i, dlsn.getSlotId());
@@ -572,9 +572,9 @@ public void testAbortShouldFailAllWrites() throws Exception {
numRecords, dlsns.size());
for (int i = 0; i < numRecords; i++) {
DLSN dlsn = dlsns.get(i);
- assertEquals("Incorrent ledger sequence number",
+ assertEquals("Incorrect ledger sequence number",
0L, dlsn.getLogSegmentSequenceNo());
- assertEquals("Incorrent entry id",
+ assertEquals("Incorrect entry id",
0L, dlsn.getEntryId());
assertEquals("Inconsistent slot id",
i, dlsn.getSlotId());
@@ -643,17 +643,17 @@ public void testUpdateLastTxIdForUserRecords() throws Exception {
numRecords + 1, dlsns.size());
for (int i = 0; i < numRecords; i++) {
DLSN dlsn = dlsns.get(i);
- assertEquals("Incorrent ledger sequence number",
+ assertEquals("Incorrect ledger sequence number",
0L, dlsn.getLogSegmentSequenceNo());
- assertEquals("Incorrent entry id",
+ assertEquals("Incorrect entry id",
0L, dlsn.getEntryId());
assertEquals("Inconsistent slot id",
i, dlsn.getSlotId());
}
DLSN dlsn = dlsns.get(numRecords);
- assertEquals("Incorrent ledger sequence number",
+ assertEquals("Incorrect ledger sequence number",
0L, dlsn.getLogSegmentSequenceNo());
- assertEquals("Incorrent entry id",
+ assertEquals("Incorrect entry id",
1L, dlsn.getEntryId());
assertEquals("Inconsistent slot id",
0L, dlsn.getSlotId());
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestReadAheadEntryReader.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestReadAheadEntryReader.java
index 6cb1e5d5f5f..1716b0902ce 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestReadAheadEntryReader.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestReadAheadEntryReader.java
@@ -236,7 +236,7 @@ public void testStartWithEmptySegmentList() throws Exception {
assertEquals(segments.size() + " log segments found, expected to be only one",
1, segments.size());
- // notify the readahead reader with new segment lsit
+ // notify the readahead reader with new segment list
readAheadEntryReader.onSegmentsUpdated(segments);
// check the reader state after initialization
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java
index 23d958dfc6c..02cd7feccb0 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java
@@ -354,8 +354,8 @@ public void testCloseAllocatorAfterAbort() throws Exception {
@Test(timeout = 60000)
public void testConcurrentAllocation() throws Exception {
- String allcationPath = "/" + runtime.getMethodName();
- SimpleLedgerAllocator allocator = createAllocator(allcationPath);
+ String allocationPath = "/" + runtime.getMethodName();
+ SimpleLedgerAllocator allocator = createAllocator(allocationPath);
allocator.allocate();
ZKTransaction txn1 = newTxn();
CompletableFuture