Skip to content

[codex] Instrument rollout persistence bytes - #29498

Merged
wiltzius-openai merged 8 commits into
mainfrom
wiltzius/codex/rollout-persistence-metrics-base
Jun 23, 2026
Merged

[codex] Instrument rollout persistence bytes#29498
wiltzius-openai merged 8 commits into
mainfrom
wiltzius/codex/rollout-persistence-metrics-base

Conversation

@wiltzius-openai

@wiltzius-openai wiltzius-openai commented Jun 22, 2026

Copy link
Copy Markdown
Contributor
  • Add 1%-sampled rollout persistence metrics that report per-item and per-thread JSON byte totals before and after filtering when metrics export is enabled.
  • Tag each item with its exact response or event variant, including nested turn-item kinds for conditionally persisted completion events, so aggregate cloud-storage impact can be estimated by policy choice.

Use exact response and event variant names in rollout persistence metrics. Include nested turn item kinds for conditionally persisted item-completed events.
@wiltzius-openai
wiltzius-openai marked this pull request as ready for review June 22, 2026 22:55

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

params: CreateThreadParams,

P2 Badge Include session metadata in byte totals

For newly created local threads that eventually materialize a rollout, the recorder writes the initial SessionMeta row before pending items, but telemetry starts with empty totals here and the only measurements are taken from later append_items calls. That means the persisted session metadata—often including base instructions and dynamic tool definitions—is never included in the per-thread post_filter byte totals, so successful new-thread shutdown metrics systematically undercount storage impact. Seed the telemetry with the created metadata or record it where the recorder writes it.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/thread-store/src/live_thread.rs Outdated
@wiltzius-openai
wiltzius-openai merged commit 02c326f into main Jun 23, 2026
31 checks passed
@wiltzius-openai
wiltzius-openai deleted the wiltzius/codex/rollout-persistence-metrics-base branch June 23, 2026 16:26
@github-actions github-actions Bot locked and limited conversation to collaborators Jun 23, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants