feat(fusillade)!: drop the plaintext API key columns (DW-1013)
Merged
TO
9d ago+526+526+012345678901234567890123456789-951-951-012345678901234567890123456789
Part 7 of 7 for DW-1005 (DW-1013). Merge only after the release containing #2172 (16.5.0) is fully deployed.
What changes
- dwctl migration
20261105123212_drop_api_keys_secret:secret_hash SET NOT NULL(instant with the validated check), drop the check, dropapi_keys.secret, refresh stale column and index comments. - fusillade migration
20261105123212_drop_stored_api_keys: recreateactive_request_templates,request_templates_allandrequest_templateswithoutapi_key, then droprequest_templates_g2.api_key. - fusillade migration
20261105143830_drop_batches_api_key: dropsbatches.api_keyon its own, so its lock isn't held with the template locks. - fusillade-core (breaking):
api_keyremoved fromRequestTemplateand every request/batch input type;create_flex/create_backgroundrequire the API key id.RequestData.api_keystays as the in-memory per-dispatch credential. - Retained response snapshots stop carrying
api_key; older ones still decode. docs/migrations.md: from 16.6.0, roll back no further than 16.5.0.
Rollout
16.5.0 neither reads nor writes these columns, so its pods keep working while the migrations run.
Not removed
DROP COLUMNdoesn't rewrite rows: old bytes stay in table pages, WAL and backups until rows are rewritten (VACUUM FULL/pg_repack) and backups expire.- Retained-response payloads written before 16.5.0 keep
template.api_keyuntil their daily partitions are retired (retained_response_retirement_enabled). Rewriting that table (~706 GB) to scrub them costs far more than retirement.
Testing
Targeted tests for the touched areas, the down-migration test, and just lint rust pass locally; CI runs the full suite.