From 2acdab02c87056e9028c04292b5410c2c314e720 Mon Sep 17 00:00:00 2001 From: Ryan Russell Date: Mon, 30 May 2022 09:19:02 -0500 Subject: [PATCH] Improve readability Signed-off-by: Ryan Russell --- replica.go | 2 +- wal_downloader.go | 4 ++-- wal_downloader_test.go | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/replica.go b/replica.go index 6541fea..245565f 100644 --- a/replica.go +++ b/replica.go @@ -105,7 +105,7 @@ func (r *Replica) Client() ReplicaClient { return r.client } // Starts replicating in a background goroutine. func (r *Replica) Start(ctx context.Context) { - // Ignore if replica is being used sychronously. + // Ignore if replica is being used synchronously. if !r.MonitorEnabled { return } diff --git a/wal_downloader.go b/wal_downloader.go index c490384..78ee240 100644 --- a/wal_downloader.go +++ b/wal_downloader.go @@ -15,12 +15,12 @@ import ( // WALDownloader represents a parallel downloader of WAL files from a replica client. // // It works on a per-index level so WAL files are always downloaded in their -// entirety and are not segmented. WAL files are downloaded from minIndex to +// entiretry and are not segmented. WAL files are downloaded from minIndex to // maxIndex, inclusively, and are written to a path prefix. WAL files are named // with the prefix and suffixed with the WAL index. It is the responsibility of // the caller to clean up these WAL files. // -// The purpose of the parallization is that RTT & WAL apply time can consume +// The purpose of the parallelization is that RTT & WAL apply time can consume // much of the restore time so it's useful to download multiple WAL files in // the background to minimize the latency. While some WAL indexes may be // downloaded out of order, the WALDownloader ensures that Next() always diff --git a/wal_downloader_test.go b/wal_downloader_test.go index f43ff17..f467a2e 100644 --- a/wal_downloader_test.go +++ b/wal_downloader_test.go @@ -383,7 +383,7 @@ func testWALDownloader(t *testing.T, parallelism int) { } }) - // Ensure a gap in indicies returns an error. + // Ensure a gap in indices returns an error. t.Run("ErrMissingMiddleIndex", func(t *testing.T) { testDir := filepath.Join("testdata", "wal-downloader", "missing-middle-index") tempDir := t.TempDir()