Repository navigation
feat(asap-tools): pooled and dashboard-style random workloads on ASAPQuery's RQE frontend - #909
Open
milindsrivastava1997 wants to merge 30 commits into
Open
milindsrivastava1997 wants to merge 30 commits into
milindsrivastava1997 wants to merge 30 commits into
Conversation
random_workload_batch.py runs every arm of the given workload sets on a cluster, one job per two-node slot, longest first; cleans a slot's nodes before each job, retries a failed job once under a new name, writes a compare_arms summary per workload (ClickHouse+MV as the reference), and keeps its state on disk so a restarted driver resumes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
On resume, a job whose run is still alive is left alone (orphaned) instead of rerun, and --skip-slots keeps the driver off busy nodes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
collate_batch.py writes one row per (set, workload, arm): CPU, memory, latency p50/p95/sum, failed queries, the feeder's ingest lag, and whether the run is valid (no failed queries, answers agreeing with Prometheus). It reports each baseline's ratio to ASAPQuery over valid pairs. plot_cost_latency.py draws p95 latency against total CPU per set, invalid runs hollow. compare_arms now reports failed queries instead of crashing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… each scatter Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…chosen arms The raw table's label-first order made every query read the whole table. The batch driver can rerun some arms under a name tag and from a config variant directory. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
It cleaned and reused them, wrecking the runs still going there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…cost-latency plot Also a figure title, thicker axes, and "total compute cost" on the y axis. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
random_workload_artifacts.py --dashboards K writes <workload>-dashK/ run configs with every query group repeated K times (e2e, VictoriaMetrics, ClickHouse and ClickHouse+MV), on the same plan, feeder and data. Each copy is its own client group and thread, so copies are issued concurrently and their latencies recorded apart. The query client's connection pool now fits every query in flight; the default 10 would open a new connection per excess request at K >= 2. collate_batch.py collates batches of an arm subset, against ClickHouse+MV when Prometheus didn't run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A workload table's gauge can carry recorded values (values.replay), which the feeder loops one step per sample in place of generated ones. make_replay.py fits Alibaba v2022 pod CPU into the random workloads' label shape and writes such a table. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Panel subtitles drop the workload set name. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…etheus and ClickHouse Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… first Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Frozen for seed 862 with saved plans for all ten workloads, for a cardinality point between base and x5. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
--pooled keeps a workload's random choices and makes its quantiles pooled (one over each group's samples; the PromQL stays the avg-of-series stand-in) and its sum top-k rank the fine grouping's groups. ClickHouse SQL renders both from the RQE. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
…tend seed-862-pooled freezes the pooled variant of the ten workloads with saved plans (expr-only, from sketch-bench eval/random-pooled e2fb479). Their pilot configs send ASAPQuery each query's tree (side file e2e.rqe_exprs.json) while Prometheus runs the PromQL; the e2e config writer reads a tree-only query's text from client_promql. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
Prometheus and VictoriaMetrics answer a pooled quantile with the avg-of-series stand-in, so those queries are left unchecked for them and the other arms' are checked against raw ClickHouse's exact pooled quantiles. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
…quantiles Prometheus and VictoriaMetrics now run quantile by (G) (phi, quantile_over_time(phi, data[100s])), which keeps the tail the pooled quantile reads. Eval tables re-exported (sketch-bench eval/random-pooled); the tree-only plans are unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
…config Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
--dashboard draws ten pooled queries per workload: a sum roll-up chain at every grouping, a p50/p90/p99 panel, pooled quantiles at the other groupings and pooled top-k by service and by microservice, over windows of 1 s to 20 m. seed-862-dashboard freezes ten, with saved plans. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
…of the dashboard template seed-862-half freezes the 5,000-series variant with saved plans. The half and x2 dashboard sets freeze workload-01 with its plan, for a cardinality sweep at 5k, 10k and 20k series. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
…uarantee The plans' DDSketch (alpha 0.1) bounds relative error at 10%; the 5% check failed answers by a hair that the plan promised. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
A 1 s top-k window rendered as [0m], which Prometheus rejects. Dashboard workloads 03, 05 and 07 re-frozen and re-exported; their plans are unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #907 (batch driver, collation and plots, time-ordered raw ClickHouse, dashboards K, Alibaba replay, x2 variant). It merges
mainfor the RQE stack (#887–890). Review the commits from556e2cdon; the earlier ones are #907's.Summary
random_workloads.py --pooled, setseed-862-pooled): the same random choices as the base set.topk(k, sum by (region, service, job) (...)).quantile by (G) (phi, quantile_over_time(phi, data[W])).--dashboard, setseed-862-dashboard, the final eval template). Ten pooled queries per workload:query_engine.frontend=rqewith a side file mapping each query's text to its tree (e2e.rqe_exprs.json). Prometheus runs the text.sketch_bench_e2e_configs.pyreads a tree-only query's text fromclient_promql.collate_batch.py): in a pooled or dashboard set, quantiles are checked against raw ClickHouse's exact pooled answers. Prometheus/VictoriaMetrics stand-ins are left unchecked.query_engine.frontend=promql, since its config's sketchdb mode reads trees.seed-862-pooledandseed-862-dashboard, 10 workloads each.Results so far (pooled w01, synthetic, all 5 systems valid)
The PromQL stand-in is 11–304% off the exact pooled quantile; ASAPQuery's pooled DDSketch is about 5% off.
Validation
python3 -m unittest discover -s tests -p "test_*.py"inasap-tools/experiments: 269 pass. New tests cover:mainresolved a conflict inmain_prometheus_client.py: the RQE protocol and the pool size are both kept.base-final-1015under the new checks gives the same 50 valid runs and ratios.🤖 Generated with Claude Code
https://claude.ai/code/session_015KzRxtgjFfFJeyDy8fN2CB