Skip to content

refactor: delete cold-store JSONL exporter + cost-model line item - #312

Merged
zzylol merged 1 commit into
mainfrom
refactor/delete-jsonl-cold-fallback
May 7, 2026
Merged

zzylol merged 1 commit into
mainfrom
refactor/delete-jsonl-cold-fallback

Conversation

@zzylol

@zzylol zzylol commented May 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Step-1 of the JSONL deprecation: drop the gateway-side raw-tee that wrote JSONL ground truth into cold/raw/ plus the deploy wiring that piped backend reads through it. The §5.2 LocalFsColdStore that consumed the JSONL was deleted in ASAPQuery-backend at the same commit (PR #95); this PR removes the producer side + the agent / compose / docs references.

Deletions

  • deploy/fake-exporter/raw_tee.go — gateway-side ground-truth JSONL writer (rawTee struct + hourBucket + Tee())
  • deploy/fake-exporter/raw_tee_test.go — its test
  • All rawTee plumbing in main.go:
    • newRawTee() invocation in main()
    • tee *rawTee parameter on runSynthetic / runTraceReplay / replayOnce
    • tee.Tee(...) calls inside the per-tick / per-row loops
    • the EXPORTER_RAW_TEE_ROOT env var read

Compose / deploy updates

  • deploy/docker-compose/e2e-overlay.yml:
    • drop the cold-store-init service (busybox seeded the /var/asap/cold/raw/ layout)
    • drop the cold-store named volume
    • drop fake-exporter's EXPORTER_RAW_TEE_ROOT env + cold-store:/var/asap/cold mount + depends_on: cold-store-init
    • drop backend's ASAP_COLD_STORE_ROOT env + --cold-store-root=/var/asap/cold flag + read-only mount
  • deploy/docker-compose/base.yml:
    • drop ASAP_COLD_STORE_* env-var family on the backend (endpoint / bucket / access-key / secret-key)
    • flip the minio-setup comment to reference the surviving Gorilla-S3 archive consumer rather than the JSONL layout
    • flip the file header comment + the minio: section header from "cold-fallback tier" to "Gorilla archive tier"

Controller

Controller cost_model already has no cold-tier scan-bytes line items — verified (no edits needed there).

Test plan

  • fake-exporter go build ./...: green
  • fake-exporter go vet ./...: green
  • compose docker compose -f base.yml -f e2e-overlay.yml config: parses
  • controller cargo test --release: 482 passed, 10 failed (all 10 fail on origin/main too — pre-existing analyzer / opamp / cost_model test bugs unrelated to this refactor)

🤖 Generated with Claude Code

Step-1 of the JSONL deprecation: drop the gateway-side raw-tee
that wrote JSONL ground truth into `cold/raw/` plus the deploy
wiring that piped backend reads through it. The §5.2
LocalFsColdStore that consumed the JSONL was deleted in
ASAPQuery-backend at the same commit (PR #95); this PR removes
the producer side + the agent / compose / docs references.

Deletions:
* `deploy/fake-exporter/raw_tee.go` — gateway-side ground-truth
  JSONL writer (rawTee struct + hourBucket + Tee())
* `deploy/fake-exporter/raw_tee_test.go` — its test
* All `rawTee` plumbing in `main.go`:
  - `newRawTee()` invocation in `main()`
  - `tee *rawTee` parameter on `runSynthetic` /
    `runTraceReplay` / `replayOnce`
  - `tee.Tee(...)` calls inside the per-tick / per-row loops
  - the `EXPORTER_RAW_TEE_ROOT` env var read

Compose / deploy updates:
* `deploy/docker-compose/e2e-overlay.yml`:
  - drop the `cold-store-init` service (busybox seeded the
    `/var/asap/cold/raw/` layout)
  - drop the `cold-store` named volume
  - drop fake-exporter's `EXPORTER_RAW_TEE_ROOT` env +
    `cold-store:/var/asap/cold` mount + `depends_on:
    cold-store-init`
  - drop backend's `ASAP_COLD_STORE_ROOT` env +
    `--cold-store-root=/var/asap/cold` flag + read-only mount
* `deploy/docker-compose/base.yml`:
  - drop `ASAP_COLD_STORE_*` env-var family on the backend
    (endpoint / bucket / access-key / secret-key)
  - flip the `minio-setup` comment to reference the surviving
    Gorilla-S3 archive consumer rather than the JSONL layout
  - flip the file header comment + the `minio:` section
    header from "cold-fallback tier" to "Gorilla archive tier"

Controller `cost_model` already has no cold-tier scan-bytes line
items — verified (no edits needed there).

Verification:
* fake-exporter `go build ./...`: green
* fake-exporter `go vet ./...`: green
* compose `docker compose -f base.yml -f e2e-overlay.yml config`: parses
* controller `cargo test --release`: 482 passed, 10 failed (all 10
  fail on origin/main too — pre-existing analyzer / opamp / cost_model
  test bugs unrelated to this refactor)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@zzylol
zzylol merged commit 0337a59 into main May 7, 2026
zzylol added a commit that referenced this pull request May 7, 2026
Step-1 of the JSONL deprecation refactor (backend PR #95 +
collector PR #312) deleted the legacy JSONL cold-fallback leg
(LocalFsColdStore, parse_jsonl, the gateway-side raw-tee, the
ColdJsonlFallback StorageBackend variant). This commit propagates
the change into the runbook + cold-engine design doc:

* docs/mvp-demo-runbook.md
  - rewrite the §"Out of scope for the demo" / §"Open gaps"
    references to point at the surviving Gorilla archive engine
    instead of the deleted JSONL ground-truth path
  - drop the LocalFsColdStore row from §Component status; rename
    the GorillaS3ColdStore row to GorillaS3Store (Step-1 rename);
    point at s3_cost.rs instead of the renamed s3_cost_tracker
  - move the "Delete LocalFsColdStore + JSONL gateway raw-tee +
    cost_model cold-tier scan-bytes" item from §Planned to DONE
  - flag Step-2 (Prometheus-TSDB block format + Thanos
    store-gateway) as the path to full PromQL parity on the
    archive tier

* docs/design-gorilla-s3-cold-engine.md
  - update §3 e2e architecture: 2-tier framing, drop the
    "raw-tee exporter (cold JSONL)" leg from the block diagram,
    drop the "cold-JSONL fallback (forwarding adapters /
    LocalFsColdStore) — UNCHANGED" branch, capability miss now
    surfaces as 404 not a JSONL scan
  - swap GorillaS3ColdStore → GorillaS3Store in the diagram
  - add the routing/ module reference (the dispatcher moved out
    of engines/router.rs in Step-1)

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@zzylol
zzylol deleted the refactor/delete-jsonl-cold-fallback branch May 9, 2026 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant