diff --git a/pageserver/src/basebackup.rs b/pageserver/src/basebackup.rs index 6da9d61879..1a7c0ad891 100644 --- a/pageserver/src/basebackup.rs +++ b/pageserver/src/basebackup.rs @@ -120,8 +120,8 @@ impl<'a> Basebackup<'a> { } // - // Generate SRLU segment files from repository. Path identifiers SLRU kind (pg_xact, pg_multixact/members, ...). - // Intiallly pass is empty string. + // Generate SLRU segment files from repository. Path identifies SLRU kind (pg_xact, pg_multixact/members, ...). + // Intially pass an empty string. // fn add_slru_segment( &mut self, diff --git a/pageserver/src/object_repository.rs b/pageserver/src/object_repository.rs index 2ee66ec261..21aaf3ce22 100644 --- a/pageserver/src/object_repository.rs +++ b/pageserver/src/object_repository.rs @@ -293,7 +293,7 @@ impl Timeline for ObjectTimeline { self.put_page_image(tag, lsn, page_img.clone(), false)?; } ObjectValue::SLRUTruncate => page_img = Bytes::from_static(&ZERO_PAGE), - _ => bail!("Invalid object kind, expected a page entry or SRLU truncate"), + _ => bail!("Invalid object kind, expected a page entry or SLRU truncate"), } // FIXME: assumes little-endian. Only used for the debugging log though let page_lsn_hi = u32::from_le_bytes(page_img.get(0..4).unwrap().try_into().unwrap()); @@ -434,7 +434,7 @@ impl Timeline for ObjectTimeline { Ok(()) } - /// Truncate SRLU segment + /// Truncate SLRU segment fn put_slru_truncate(&self, tag: ObjectTag, lsn: Lsn) -> Result<()> { let key = ObjectKey { timeline: self.timelineid, diff --git a/pageserver/src/repository.rs b/pageserver/src/repository.rs index f070ab02f6..6bc212d85f 100644 --- a/pageserver/src/repository.rs +++ b/pageserver/src/repository.rs @@ -97,7 +97,7 @@ pub trait Timeline: Send + Sync { /// Unlink relation. This method is used for marking dropped relations. fn put_unlink(&self, tag: RelTag, lsn: Lsn) -> Result<()>; - /// Truncate SRLU segment + /// Truncate SLRU segment fn put_slru_truncate(&self, tag: ObjectTag, lsn: Lsn) -> Result<()>; // Get object tag greater or equal than specified diff --git a/pageserver/src/walredo.rs b/pageserver/src/walredo.rs index 8d965f9a84..e43b9c354a 100644 --- a/pageserver/src/walredo.rs +++ b/pageserver/src/walredo.rs @@ -278,17 +278,17 @@ impl PostgresRedoManagerInternal { // Relational WAL records are applied using wal-redo-postgres apply_result = process.apply_wal_records(buf_tag, base_img, records).await; } else { - // Non-relational WAL records we will aply ourselves. + // Non-relational WAL records we apply ourselves. const ZERO_PAGE: [u8; 8192] = [0u8; 8192]; let mut page = BytesMut::new(); if let Some(fpi) = base_img { // If full-page image is provided, then use it... page.extend_from_slice(&fpi[..]); } else { - // otherwise initialize page with zeros + // otherwise initialize page with zeros page.extend_from_slice(&ZERO_PAGE); } - // Apply all callected WAL records + // Apply all collected WAL records for record in records { let mut buf = record.rec.clone(); diff --git a/postgres_ffi/src/xlog_utils.rs b/postgres_ffi/src/xlog_utils.rs index 67e2e03469..272815d153 100644 --- a/postgres_ffi/src/xlog_utils.rs +++ b/postgres_ffi/src/xlog_utils.rs @@ -447,7 +447,7 @@ pub fn generate_wal_segment(pg_control: &ControlFileData) -> Bytes { seg_buf.extend_from_slice(&rec_shord_hdr_bytes); seg_buf.extend_from_slice(&checkpoint_bytes); - //zero out remainig file + //zero out the rest of the file seg_buf.resize(pg_constants::WAL_SEGMENT_SIZE, 0); seg_buf.freeze() }