Kamera Debugging for KICK
KICK includes optional kamera tooling for structural control-plane analysis and exploration artifact inspection.
Upstream: https://github.com/tgoodwin/kamera
Install
From repo root:
make kamera
bin/kamera --helpThe Make target installs:
go install github.com/tgoodwin/kamera/cmd/kamera@mainKICK example you can run now
This repository now includes a concrete KICK graph example with real KICK resource kinds:
- docs/development/examples/kamera/kick-dependency-graph.json
It models:
- SourceObservationReconciler
- KickRequestReconciler
- core/v1 Secret + ConfigMap
- apps/v1 Deployment
- kick.corewire.io/v1alpha1 KickRequest
1) Detect hotspots in the KICK graph
bin/kamera inspect hotspots docs/development/examples/kamera/kick-dependency-graph.jsonExpected hotspot types in output:
- multi_writer on KickRequest status
- feedback_cycle on KickRequestReconciler <-> KickRequest
- reducer_controller on KickRequestReconciler
- missing_trigger on resources KickRequestReconciler reads but does not directly watch
This gives a fast structural risk scan before runtime debugging.
2) Render dependency graph PDF
bin/kamera inspect dependency-graph docs/development/examples/kamera/kick-dependency-graph.jsonOn Linux this uses xdg-open and reports a temp PDF path such as:
opened dependency graph from docs/development/examples/kamera/kick-dependency-graph.json
pdf saved at /tmp/dependency-graph-<id>.pdfUse this graph during design reviews for controller/resource coupling.
Exploration dumps (when you have one)
If you have an exploration dump file or directory from a kamera harness:
bin/kamera inspect exploration <dump.jsonl>
bin/kamera inspect exploration --interactive=false <dump.jsonl>
bin/kamera analyze report <dump.jsonl>
bin/kamera analyze diff <dump.jsonl>For headless CI triage, prefer:
bin/kamera inspect exploration --interactive=false <dump.jsonl>This prints DAG + node details directly to stdout.
Determinize helper
Kamera also provides deterministic time rewrite tooling:
bin/kamera determinize [paths...]Use this on isolated experiments, not as a blanket rewrite of the repository.
KICK workflow recommendation
- Reproduce issue with existing checks (
make test,make test-e2e-scenario E2E=...). - Run hotspot scan on a graph snapshot of the affected controllers/resources.
- Inspect exploration dumps (if available) to isolate ordering-sensitive paths.
- Convert findings into deterministic unit/envtest/e2e assertions in KICK.
Notes
- kamera generate currently depends on upstream translation code paths that are evolving; prefer inspect/analyze workflows for now.
- kamera tagged module versions currently lag cmd/kamera availability, so this repository pins installation to main.