Skip to content

Commit d9e123a

Browse files
feat(query-engine): gate legacy SimpleMapStore behind a feature flag
Legacy SimpleMapStoreGlobal/PerKey implement the Store trait but are only used by the simple_store_bench comparison benchmark. Gating them behind an off-by-default legacy_stores feature means future Store trait changes don't need to touch the legacy variants.
1 parent b352f88 commit d9e123a

2 files changed

Lines changed: 7 additions & 0 deletions

File tree

‎asap-query-engine/Cargo.toml‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ criterion = { version = "0.5", features = ["html_reports"] }
8787
[[bench]]
8888
name = "simple_store_bench"
8989
harness = false
90+
required-features = ["legacy_stores"]
9091

9192
[features]
9293
#default = ["lock_profiling", "extra_debugging"]
@@ -97,3 +98,8 @@ jemalloc = ["dep:tikv-jemallocator"]
9798
lock_profiling = []
9899
# Enable extra debugging output
99100
extra_debugging = []
101+
# Legacy SimpleMapStore implementations, kept only for the simple_store_bench
102+
# comparison benchmark. Off by default so the Store trait's real implementors
103+
# are just SimpleMapStoreGlobal/PerKey — adding a Store trait method doesn't
104+
# require updating the legacy variants.
105+
legacy_stores = []

‎asap-query-engine/src/stores/simple_map_store/mod.rs‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
mod common;
22
pub mod global;
3+
#[cfg(feature = "legacy_stores")]
34
pub mod legacy;
45
pub mod per_key;
56

0 commit comments

Comments
 (0)