Skip to content

refactor: split runtime state ownership#244

Merged
Nek-12 merged 3 commits into
mainfrom
td-06
May 12, 2026
Merged

refactor: split runtime state ownership#244
Nek-12 merged 3 commits into
mainfrom
td-06

Conversation

@Nek-12

@Nek-12 Nek-12 commented May 11, 2026

Copy link
Copy Markdown
Member

Summary

  • Split runtime and registry state ownership into focused subdomain owners for registry coordination, runtime state stores, transcript persistence, and compaction planning/execution/persistence/reminders/carryover.
  • Added invariant/state-machine regression tests for new stores, self-deadlock guard, model/tool cancellation, prompt close/cancel semantics, and compaction durable-before-memory ordering.
  • Rebased on top of main.

Verification

  • ./scripts/test.sh ./server/runtime ./server/registry -count=1
  • ./scripts/build.sh --output ./bin/builder
  • git diff --check
  • push hook: formatting, go vet, go build, test

@coderabbitai

coderabbitai Bot commented May 11, 2026

Copy link
Copy Markdown
Contributor

Warning

Rate limit exceeded

@Nek-12 has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 43 minutes and 1 second before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 49947be2-c639-43a7-ac67-aaa50adeb75e

📥 Commits

Reviewing files that changed from the base of the PR and between 5e0e755 and a115a0b.

📒 Files selected for processing (56)
  • server/registry/pending_prompt_store.go
  • server/registry/primary_run_lease_store.go
  • server/registry/prompt_activity_broker.go
  • server/registry/runtime_directory.go
  • server/registry/runtime_registry.go
  • server/registry/runtime_registry_test.go
  • server/registry/session_activity_broker.go
  • server/runtime/committed_transcript_events_test.go
  • server/runtime/compaction.go
  • server/runtime/compaction_carryover.go
  • server/runtime/compaction_executor.go
  • server/runtime/compaction_persistence.go
  • server/runtime/compaction_planner.go
  • server/runtime/compaction_reminder.go
  • server/runtime/compaction_runtime_state.go
  • server/runtime/compaction_utils.go
  • server/runtime/diagnostic_dedupe_store.go
  • server/runtime/engine.go
  • server/runtime/engine_message_ops.go
  • server/runtime/engine_part11_test.go
  • server/runtime/engine_part12_test.go
  • server/runtime/engine_part13_test.go
  • server/runtime/engine_part14_test.go
  • server/runtime/engine_part15_test.go
  • server/runtime/engine_part4_test.go
  • server/runtime/engine_part8_test.go
  • server/runtime/engine_part9_test.go
  • server/runtime/engine_queue_submission.go
  • server/runtime/engine_request.go
  • server/runtime/engine_state.go
  • server/runtime/engine_state_deadlock_test.go
  • server/runtime/goal.go
  • server/runtime/goal_loop_state.go
  • server/runtime/goal_test.go
  • server/runtime/handoff_runtime_state.go
  • server/runtime/locked_contract_state.go
  • server/runtime/message_lifecycle.go
  • server/runtime/model_cancellation_test.go
  • server/runtime/model_request_runtime_state.go
  • server/runtime/orchestration_collaborators.go
  • server/runtime/pending_tool_call_starts.go
  • server/runtime/phase_protocol.go
  • server/runtime/phase_protocol_state.go
  • server/runtime/queued_user_messages.go
  • server/runtime/request_cache_lineage.go
  • server/runtime/request_cache_lineage_test.go
  • server/runtime/reviewer_runtime_state.go
  • server/runtime/state_stores_test.go
  • server/runtime/status_inspection.go
  • server/runtime/step_executor.go
  • server/runtime/system_prompt_snapshot.go
  • server/runtime/tool_executor_cancellation_test.go
  • server/runtime/transcript_persistence.go
  • server/runtime/transcript_runtime_state.go
  • server/runtime/usage_tracking_state.go
  • server/runtime/worktree_reminder_test.go
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch td-06

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ddd227db8a

ℹ️ 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 server/runtime/compaction_persistence.go Outdated
@Nek-12 Nek-12 merged commit 2e9ca70 into main May 12, 2026
6 checks passed
@Nek-12 Nek-12 deleted the td-06 branch May 12, 2026 12:38
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