feat: series-aggregation SDK benchmark (--series-per-sketch) - #53
Merged
Merged
Conversation
Extend e2esdkbench with --series-per-sketch flag so N series can be collapsed into one sketch before export, reducing OTLP data-point count from series → series/N. Add bench_series_agg.sh to sweep group sizes against a baseline (raw per-series gauges), both hitting a no-op collector, recording SDK bandwidth, CPU, heap and collector CPU/RSS. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Rename GROUPS→SWEEP_GROUPS in bench_series_agg.sh (bash read-only var conflict) - Fix readerInterval logic in e2esdkbench (baseline uses workerInterval, sketches use 1s) - Sync all patch folders with current submodule state Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
backup_all.sh uses rm -rf when copying untracked directories from submodules, wiping config-window.yaml and config-bench.yaml from patch folders. Restore the 8 deleted files from the previous commit so bench_sdk_e2e.sh can still find its collector configs. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replace rm -rf + cp -R with mkdir -p + cp -R src/. dest/ so that patch-only files (e.g. config-window.yaml) are preserved when an untracked directory in the submodule triggers a directory-level copy. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This reverts commit ec6a991.
This reverts commit 7237586.
- bench_series_agg.sh: rename GROUPS→SWEEP_GROUPS (bash read-only var) - e2esdkbench/main.go: fix readerInterval — sketches use 1s, baseline uses workerInterval (was inverted) - cmd/kll/build-config.yaml: uncomment sketchlib-go replace so builder picks up local Reset() instead of stale module cache - cmd/hllcol/build-config.yaml: add sketchlib-go replace (same fix) - Sync patch dirs and rebuilt KLL binary Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…th replaces)
Pull main (49890c7) which includes merged add-reset-methods (Reset() on
KLL and HLL) and aligned-sketch-implementation. Update all go.mod/go.sum
that previously pinned to /mydata/sketchlib-go:
- processor/{kll,hll,countminsketck,countsketch}processor
- opentelemetry-go sdk/metric and otlpmetric{grpc,http} exporters
- opentelemetry-app
Remove local replace directives; remove local path from KLL and HLL
builder configs. All 4 collector binaries and e2esdkbench rebuild clean.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
SieDeta
pushed a commit
that referenced
this pull request
Apr 17, 2026
…-timestamp feat: series-aggregation SDK benchmark (--series-per-sketch)
Merged
5 tasks
zzylol
added a commit
that referenced
this pull request
May 5, 2026
…ib-go rename adaptation (#262) Two independent blockers prevented `asap/fake-exporter:dev` from rebuilding off main HEAD; both fixed. ## Blocker A — missing Go bindings for opentelemetry-proto-patch The patched `metrics.proto` adds five sketch message types (DDSketch / KLLSketch / CountSketch / CountMinSketch / HLLSketch) on top of upstream v1.9.0, but the regenerated `.pb.go` files were never committed. Every build hit `undefined: mpb.Metric_Ddsketch / mpb.DDSketchDataPoint / ...` in the patched OTLP transform layer. Fix: regenerated the Go bindings via the upstream `make gen-go` recipe (otel/build-protobuf:0.9.0 image, `--go_out=plugins=grpc`) over a clean v1.9.0 + the patched `.proto` files; committed all 10 `.pb.go` outputs (11,385 lines total) under `opentelemetry-proto-patch/gen/go/...`. Updated `.gitignore` to track that subtree. Added an explicit `go.opentelemetry.io/proto/otlp` replace in `deploy/fake-exporter/go.mod` pointing at the gen tree (the dependency module's replace isn't honored from a downstream main module). Updated `Dockerfile.fake-exporter` to copy `opentelemetry-proto/` into the build context so the relative replace path resolves. Wrote `opentelemetry-proto-patch/REGEN.md` with the full regeneration recipe. ## Blocker B — sketchlib-go API rename refactor (PR #53) absorption The patched OTLP transform files referenced `metricdata.KLLSketchEncodingGob`, `metricdata.CountSketchEncodingGob`, `metricdata.CountMinSketchEncodingGob` and the corresponding `mpb.*_ENCODING_GOB` enum values. Those names were renamed to `*EncodingProto` / `*EncodingDelta` and `*_ENCODING_PROTO` / `*_ENCODING_DELTA` by the gob→proto encoding rename (commit b031975) and by sketchlib-go PR #53. Fix: updated KLL/CountSketch/CountMinSketch encoding switches in both the otlpmetricgrpc and otlpmetrichttp transform packages to dispatch on the post-rename names. CountSketch/CountMinSketch get the additional Delta arm matching the sketch wire's sparse-delta path; KLL keeps a single Proto arm (no delta defined for KLL). The sketchlib-go API renames per PR #53 (`Add`/`Insert` → `Update` on per-value, `InsertValue` → `UpdateValue` on HLL, `Insert(input)` / `OctoInsert` → `Update`, `EstimateCardinality()` → `Estimate()` on HLL, `GetValueAtQuantile` → `Quantile` on DDSketch, `InsertWeight`/`InsertBatch`/`InsertHashes`/`BulkInsert` → `UpdateWeight`/`UpdateBatch`/`UpdateHashes`/`BulkUpdate`) were already absorbed into the patched `sdk/metric/internal/aggregate/{hllsketch, kllsketch,countminsketch,countsketch,ddsketch}.go` and `asap-precompute-go/sketches/hll.go` before this round; the rebuild verifies they're correct. ## Verification - `docker builder prune -af` then `DOCKER_BUILDKIT=1 docker build -f deploy/docker/Dockerfile.fake-exporter --build-context sketchlib-go=/path/to/sketchlib-go -t asap/fake-exporter:dev .` → clean cold-cache build. - `go build ./...` and `go test ./...` clean in `opentelemetry-go/sdk/metric/` and `asap-precompute-go/`. - Recreated against the live E0 stack (b3-delta + e2e-overlay, N=1): `docker compose ... up -d --force-recreate fake-exporter` → clean startup logs, container Up 30s with no errors.
This was referenced May 5, 2026
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.
Summary
--series-per-sketch Nflag toe2esdkbenchso workers aggregate N series into one sketch before export (using a coarsergroup.idattribute instead of per-seriesseries.id). When N ≥ total series or N=0, all series collapse into a single sketch.SeriesPerSketchfield to the summary JSON/struct so results carry the grouping parameter._grpN_suffix when N≠1 (e.g.ddsketch_grp100_50000mps_summary.json) preserving backward compatibility with existingbench_sdk_e2e.shruns.otel_collector_benchmark/bench_series_agg.shsweeps over configurable--groupsvalues against a single baseline run, always using the no-op collector (nopcol). Produces per-run timeseries CSVs, summary JSONs, collector resource CSVs, and a combinedaggregate_summary.csvwith abw_reduction_vs_baseline_pctcolumn.Benchmark Results
Full e2e run: 50,000 MPS · 1,000 series · 60s duration · nopcol collector
Bandwidth (avg KB/s) and reduction vs raw baseline
SDK CPU % at each group size
Avg heap (MB) at each group size
Key observations
Test plan
go build ./cmd/e2esdkbenchpassesbench_sdk_e2e.shbehaviour unchanged (no--series-per-sketchflag → default 1 → original filenames)🤖 Generated with Claude Code