Skip to content

feat(batch-worker): bind the Omi flag store on the GPU worker chart - #26466

Merged
Nizarius merged 1 commit into
mainfrom
feat/batch-worker-flag-store
Nov 27, 2026
Merged

Nizarius merged 1 commit into
mainfrom
feat/batch-worker-flag-store

Conversation

@Nizarius

Copy link
Copy Markdown
Collaborator

What changed and why

The batch GPU worker chart can now bind the Omi flag store (OMI_FLAGS_FIRESTORE_PROJECT, OMI_FLAGS_FIRESTORE_DATABASE), and the production values set it to the store the serving roles already read.

The reliability experiment commit_wake (#26348) is decided per owner in two places: the worker that commits a result and the serving backend that receives the wake. The serving roles read the flag store; the worker chart had no binding, so the worker's check read off for every owner and a rule could not admit anyone there. The registry row for commit_wake already names this as its precondition.

Nothing changes in behaviour with this PR alone:

  • No rule admits an owner on the worker until this binding is rolled out and a rule exists; with the binding and no admitted owner the worker sends nothing.
  • The binding is values-driven. Dev and staging values leave it empty, which renders no binding, as today.
  • Cost of the binding: each pump process re-reads the store's small version document at most once a minute, and only while it is committing results; the rules are reloaded only when the version changes. This is the same reader the serving roles run.

Roll note for the release owner: the preserve-live image-only worker release keeps the live environment, so this binding arrives only with a chart roll of the worker. The worker's service account needs read access to the flag database; please confirm it at roll time. A chart roll also applies every other value of the production values file, so compare the live worker with the rendered chart first (pump depth in particular).

Product invariants affected

none

How it was verified

  • helm template through the chart test helper with the production values: the three GPU pump deployments (primary, T4 fallback, borrower) carry both names with the values of deploy/runtime_env/prod.overlay.yaml; the record-seal worker, a different program, carries neither. With default values no deployment carries them.
  • bash test.sh over tests/unit/test_batch_pipeline_chart.py, tests/unit/test_batch_pipeline_cohort_config.py and tests/unit/test_cross_service_deploy_contract.py: all pass, including the two new tests. On this Mac the test_rollout_wait_* / test_rollout_verify_* cases need GNU timeout, which macOS lacks; they were run with a local stand-in for it.
  • The pre-push suite selected for this change passed except tests/unit/test_monitoring_notification_contract.py, which needs Go (not installed here) and reads nothing this PR touches; left to CI.
  • helm lint of the chart with the production values: no failures.
  • Not verified: nothing was deployed. The worker reading the store in production, and a wake sent for an admitted owner, are not exercised by this PR.

Tests

backend/tests/unit/test_batch_pipeline_chart.py:

  • test_production_workers_read_the_flag_store_the_serving_roles_read: every GPU pump deployment rendered from the production values names the same project and database as the serving integration role in the runtime manifest.
  • test_worker_without_a_flag_store_renders_no_flag_store_binding: the default chart renders no OMI_FLAGS_* name.

UI evidence

UI-Evidence: none -- chart values and a chart test only

Failure class (fixes)

Failure-Class: none

🤖 Generated with Claude Code

The reliability experiment commit_wake is decided per owner on the worker
that commits a result and on the serving backend that receives the wake.
The serving roles read the Omi flag store; the worker chart had no binding,
so the worker's check read off for every owner.

The chart now renders OMI_FLAGS_FIRESTORE_PROJECT and
OMI_FLAGS_FIRESTORE_DATABASE from worker.flagStoreProject and
worker.flagStoreDatabase. Production sets them to the store the serving
roles read; dev and staging leave them empty, which renders nothing.
No rule admits an owner on the worker until a rule exists, so behaviour is
unchanged until then.

Failure-Class: none

Co-Authored-By: Claude Fable 5.2 <[email protected]>
@Nizarius
Nizarius merged commit c1dd7fc into main Nov 27, 2026
67 checks passed
@Nizarius
Nizarius deleted the feat/batch-worker-flag-store branch November 27, 2026 02:01
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