Skip to content

Commit cb9eaa0

Browse files
zzylolclaude
authored andcommitted
fix: extract GroupedBatch type alias to satisfy clippy::type_complexity
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent da11689 commit cb9eaa0

1 file changed

Lines changed: 10 additions & 8 deletions

File tree

  • asap-query-engine/src/stores/simple_map_store

asap-query-engine/src/stores/simple_map_store/global.rs

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,15 @@ impl SimpleMapStoreGlobal {
157157
}
158158

159159
/// Extracted config fields needed inside the locked batch loop.
160+
type GroupedBatch = HashMap<
161+
StoreKey,
162+
(
163+
BatchConfig,
164+
u64,
165+
Vec<(PrecomputedOutput, Box<dyn AggregateCore>)>,
166+
),
167+
>;
168+
160169
/// Pre-computed outside the lock to avoid per-item config lookups (Opt 4).
161170
struct BatchConfig {
162171
metric: String,
@@ -186,14 +195,7 @@ impl Store for SimpleMapStoreGlobal {
186195
// Config lookups (streaming_config HashMap access) are moved out of the hot locked
187196
// loop: each unique aggregation_id pays one lookup regardless of batch size.
188197
// Also pre-compute batch_min_ts per group to collapse N earliest-ts updates into 1.
189-
let mut grouped: HashMap<
190-
StoreKey,
191-
(
192-
BatchConfig,
193-
u64,
194-
Vec<(PrecomputedOutput, Box<dyn AggregateCore>)>,
195-
),
196-
> = HashMap::new();
198+
let mut grouped: GroupedBatch = HashMap::new();
197199

198200
for (output, precompute) in outputs {
199201
let aggregation_config = self

0 commit comments

Comments
 (0)