From 5674ef029ac601f05b41bf43a25245c873a7674f Mon Sep 17 00:00:00 2001 From: WenyXu Date: Tue, 27 Aug 2024 02:55:36 +0000 Subject: [PATCH] chore: apply suggestions from CR --- src/log-store/src/kafka/index.rs | 2 +- src/mito2/src/wal.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/log-store/src/kafka/index.rs b/src/log-store/src/kafka/index.rs index a16b605702e1..fa98f3fcaf90 100644 --- a/src/log-store/src/kafka/index.rs +++ b/src/log-store/src/kafka/index.rs @@ -26,5 +26,5 @@ pub(crate) use iterator::{ pub(crate) use iterator::{MultipleRegionWalIndexIterator, RegionWalRange, RegionWalVecIndex}; pub fn default_index_file(location_id: u64) -> String { - format!("__datanode/{location_id}/index.json") + format!("__wal/{location_id}/index.json") } diff --git a/src/mito2/src/wal.rs b/src/mito2/src/wal.rs index 22324821033a..710c0ee3c807 100644 --- a/src/mito2/src/wal.rs +++ b/src/mito2/src/wal.rs @@ -109,9 +109,9 @@ impl Wal { LogStoreRawEntryReader::new(self.store.clone()), )), Provider::Kafka(_) => { - let reader = if let Some(from_peer_id) = location_id { + let reader = if let Some(location_id) = location_id { LogStoreRawEntryReader::new(self.store.clone()) - .with_wal_index(WalIndex::new(region_id, from_peer_id)) + .with_wal_index(WalIndex::new(region_id, location_id)) } else { LogStoreRawEntryReader::new(self.store.clone()) };