From 0e4cbe01652d9a6f0fa2a80db8e8cc066575f6f5 Mon Sep 17 00:00:00 2001 From: Kirill Bulatov Date: Thu, 2 Sep 2021 17:20:22 +0300 Subject: [PATCH] Fix some typos --- pageserver/src/basebackup.rs | 2 +- pageserver/src/bin/pageserver.rs | 2 +- pageserver/src/layered_repository.rs | 2 +- pageserver/src/page_service.rs | 2 +- postgres_ffi/src/controlfile_utils.rs | 2 +- test_runner/fixtures/benchmark_fixture.py | 2 +- zenith/src/main.rs | 2 +- zenith_metrics/src/wrappers.rs | 2 +- zenith_utils/src/auth.rs | 2 +- zenith_utils/src/bin_ser.rs | 2 +- zenith_utils/src/http/endpoint.rs | 2 +- 11 files changed, 11 insertions(+), 11 deletions(-) diff --git a/pageserver/src/basebackup.rs b/pageserver/src/basebackup.rs index 6eb40bead4..86c17e349e 100644 --- a/pageserver/src/basebackup.rs +++ b/pageserver/src/basebackup.rs @@ -53,7 +53,7 @@ impl<'a> Basebackup<'a> { } = if let Some(lsn) = req_lsn { // FIXME: that wouldn't work since we don't know prev for old LSN's. // Probably it is better to avoid using prev in compute node start - // at all and acept the fact that first WAL record in the timeline would + // at all and accept the fact that first WAL record in the timeline would // have zero as prev. https://github.com/zenithdb/zenith/issues/506 RecordLsn { last: lsn, diff --git a/pageserver/src/bin/pageserver.rs b/pageserver/src/bin/pageserver.rs index f9852a3276..c91f6a4b9f 100644 --- a/pageserver/src/bin/pageserver.rs +++ b/pageserver/src/bin/pageserver.rs @@ -284,7 +284,7 @@ fn start_pageserver(conf: &'static PageServerConf) -> Result<()> { if conf.daemonize { info!("daemonizing..."); - // There should'n be any logging to stdin/stdout. Redirect it to the main log so + // There shouldn't be any logging to stdin/stdout. Redirect it to the main log so // that we will see any accidental manual fprintf's or backtraces. let stdout = log_file.try_clone().unwrap(); let stderr = log_file; diff --git a/pageserver/src/layered_repository.rs b/pageserver/src/layered_repository.rs index 287c04f3e0..6f8b966dc9 100644 --- a/pageserver/src/layered_repository.rs +++ b/pageserver/src/layered_repository.rs @@ -1052,7 +1052,7 @@ impl LayeredTimeline { // FIXME: we can deadlock if we call wait_lsn() from WAL receiver. And we actually // it a lot from there. Only deadlock that I caught was while trying to add wait_lsn() // in list_rels(). But it makes sense to make all functions in timeline non-waiting; - // assert that arg_lsn <= current_record_lsn; call wait_lsn explicetly where it is + // assert that arg_lsn <= current_record_lsn; call wait_lsn explicitly where it is // needed (page_service and basebackup); uncomment this check: // assert_ne!(thread::current().name(), Some("WAL receiver thread")); diff --git a/pageserver/src/page_service.rs b/pageserver/src/page_service.rs index 60e7f65078..ce2e87de92 100644 --- a/pageserver/src/page_service.rs +++ b/pageserver/src/page_service.rs @@ -492,7 +492,7 @@ impl postgres_backend::Handler for PageServerHandler { // branch_create // TODO lazy static - // TOOD: escaping, to allow branch names with spaces + // TODO: escaping, to allow branch names with spaces let re = Regex::new(r"^branch_create ([[:xdigit:]]+) (\S+) ([^\r\n\s;]+)[\r\n\s;]*;?$") .unwrap(); let caps = re.captures(&query_string).ok_or_else(err)?; diff --git a/postgres_ffi/src/controlfile_utils.rs b/postgres_ffi/src/controlfile_utils.rs index c9b11b28a9..9805dff5fb 100644 --- a/postgres_ffi/src/controlfile_utils.rs +++ b/postgres_ffi/src/controlfile_utils.rs @@ -11,7 +11,7 @@ //! data directory is compatible with a postgres binary. That includes //! a version number, configuration options that can be set at //! compilation time like the block size, and the platform's alignment -//! and endianess information. (The PostgreSQL on-disk file format is +//! and endianness information. (The PostgreSQL on-disk file format is //! not portable across platforms.) //! //! The control file is stored in the PostgreSQL data directory, as diff --git a/test_runner/fixtures/benchmark_fixture.py b/test_runner/fixtures/benchmark_fixture.py index 708577f0bf..43e6646d0c 100644 --- a/test_runner/fixtures/benchmark_fixture.py +++ b/test_runner/fixtures/benchmark_fixture.py @@ -78,7 +78,7 @@ class ZenithBenchmarkResults: self.results.append((test_name, metric_name, metric_value, unit)) -# Sesssion scope fixture that initializes the results object +# Session scope fixture that initializes the results object @pytest.fixture(autouse=True, scope='session') def zenbenchmark_global(request) -> Iterator[ZenithBenchmarkResults]: """ diff --git a/zenith/src/main.rs b/zenith/src/main.rs index 8ba688407e..fdaab7555a 100644 --- a/zenith/src/main.rs +++ b/zenith/src/main.rs @@ -95,7 +95,7 @@ fn main() -> Result<()> { .required(false) )) .subcommand(SubCommand::with_name("start") - .about("Start a postrges compute node.\n This command actually creates new node from scrath, but preserves existing config files") + .about("Start a postgres compute node.\n This command actually creates new node from scratch, but preserves existing config files") .arg(timeline_arg.clone()).arg(tenantid_arg.clone())) .subcommand( SubCommand::with_name("stop") diff --git a/zenith_metrics/src/wrappers.rs b/zenith_metrics/src/wrappers.rs index 88b9f88740..48202bc15e 100644 --- a/zenith_metrics/src/wrappers.rs +++ b/zenith_metrics/src/wrappers.rs @@ -186,7 +186,7 @@ mod tests { assert_eq!(total, stream.len()); } - // This mimicks the constraints of std::thread::spawn + // This mimics the constraints of std::thread::spawn fn assert_send_sync(_x: impl Sync + Send + 'static) {} #[test] diff --git a/zenith_utils/src/auth.rs b/zenith_utils/src/auth.rs index 719580384b..1432cca72e 100644 --- a/zenith_utils/src/auth.rs +++ b/zenith_utils/src/auth.rs @@ -1,6 +1,6 @@ // For details about authentication see docs/authentication.md // TODO there are two issues for our use case in jsonwebtoken library which will be resolved in next release -// The fisrt one is that there is no way to disable expiration claim, but it can be excluded from validation, so use this as a workaround for now. +// The first one is that there is no way to disable expiration claim, but it can be excluded from validation, so use this as a workaround for now. // Relevant issue: https://github.com/Keats/jsonwebtoken/issues/190 // The second one is that we wanted to use ed25519 keys, but they are also not supported until next version. So we go with RSA keys for now. // Relevant issue: https://github.com/Keats/jsonwebtoken/issues/162 diff --git a/zenith_utils/src/bin_ser.rs b/zenith_utils/src/bin_ser.rs index 71b07348b2..2d6b4c8bab 100644 --- a/zenith_utils/src/bin_ser.rs +++ b/zenith_utils/src/bin_ser.rs @@ -6,7 +6,7 @@ //! //! The [`LeSer`] trait does the same thing, in little-endian form. //! -//! Note: you will get a compile error if you try to `use` both trais +//! Note: you will get a compile error if you try to `use` both traits //! in the same module or scope. This is intended to be a safety //! mechanism: mixing big-endian and little-endian encoding in the same file //! is error-prone. diff --git a/zenith_utils/src/http/endpoint.rs b/zenith_utils/src/http/endpoint.rs index 2c476a2758..a03def659a 100644 --- a/zenith_utils/src/http/endpoint.rs +++ b/zenith_utils/src/http/endpoint.rs @@ -145,7 +145,7 @@ pub fn serve_thread_main( addr: String, ) -> anyhow::Result<()> { let addr = addr.parse()?; - log::info!("Starting a http endoint at {}", addr); + log::info!("Starting an http endpoint at {}", addr); // Create a Service from the router above to handle incoming requests. let service = RouterService::new(router_builder.build().map_err(|err| anyhow!(err))?).unwrap();