Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 12 additions & 37 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion asap-query-engine/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ figment = { version = "0.10", features = ["yaml"] }
arc-swap = "1"
csv = "1"
elastic_dsl_utilities.workspace = true
asap_sketchlib = { git = "https://github.com/ProjectASAP/asap_sketchlib" }
asap_sketchlib = { git = "https://github.com/ProjectASAP/asap_sketchlib", branch = "refactor/module-restructure" }

[[bin]]
name = "precompute_engine"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,11 @@ impl AccumulatorUpdater for CmsAccumulatorUpdater {
}

fn update_keyed(&mut self, key: &KeyByLabelValues, value: f64, _timestamp_ms: i64) {
self.acc.inner.update(&key.to_semicolon_str(), value);
crate::precompute_operators::sketchlib_runtime::cms_update(
&mut self.acc.inner,
&key.to_semicolon_str(),
value,
);
}

impl_clone_accumulator_methods!(acc);
Expand Down Expand Up @@ -855,6 +859,6 @@ mod tests {
.as_any()
.downcast_ref::<crate::precompute_operators::datasketches_kll_accumulator::DatasketchesKLLAccumulator>()
.expect("should be KLL");
assert_eq!(kll.inner.k, 50, "k should be 50 from capital-K param");
assert_eq!(kll.inner.k(), 50, "k should be 50 from capital-K param");
}
}
4 changes: 2 additions & 2 deletions asap-query-engine/src/precompute_engine/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,7 @@ mod tests {
use crate::precompute_operators::datasketches_kll_accumulator::DatasketchesKLLAccumulator;
use crate::precompute_operators::multiple_sum_accumulator::MultipleSumAccumulator;
use crate::precompute_operators::sum_accumulator::SumAccumulator;
use asap_sketchlib::sketches::kll::KllSketch;
use asap_sketchlib::KllSketch;
use asap_types::enums::{AggregationType, WindowType};

fn make_agg_config(
Expand Down Expand Up @@ -1511,7 +1511,7 @@ mod tests {
handcrafted_output.end_timestamp,
arroyo_output.end_timestamp
);
assert_eq!(handcrafted_acc.inner.k, arroyo_acc.inner.k);
assert_eq!(handcrafted_acc.inner.k(), arroyo_acc.inner.k());
assert_eq!(handcrafted_acc.inner.count(), arroyo_acc.inner.count());

for quantile in [0.0, 0.5, 1.0] {
Expand Down
Loading
Loading