fix(staging): preserve staged benchmark runs / 修复预发布基准测试运行持久化 - #643
Merged
Conversation
Keep normal staging ingests cumulative and expose an explicit manual reset that restores the Neon branch from production. Re-staging remains idempotent for the selected workflow run. 中文:修复预发布流程,使常规写入累积保留已发布的基准测试运行;仅在显式手动重置时从生产环境恢复 Neon 分支。重复发布同一工作流运行仍保持幂等更新。
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/stage-resultsingests another run.reset-staging-databaseoption for intentionally restoring Neon staging from production before an ingest.Why
The staging workflow currently restores the Neon staging branch from production before every ingest. That makes staging a single replaceable slot: staging run B deletes staged run A. Staging is intended to accumulate independently addressable runs, with replacement scoped to the same run ID.
Companion PR
InferenceX PR #2412 updates
/stage-resultsacknowledgment and completion messages to describe the persistent behavior.Validation
actionlint .github/workflows/stage-results.ymlbun run fmtbun run lintbun run typecheckbun run test:unit— 3,441 tests passed中文说明
变更概述
/stage-results写入新运行时,继续保留此前已发布的基准测试运行。reset-staging-database选项,需要明确选择后才会在写入前从生产环境恢复 Neon staging。背景
当前预发布工作流会在每次写入前将 Neon staging 分支恢复到生产数据库状态,因此预发布环境实际上只有一个可替换槽位:发布运行 B 会删除此前发布的运行 A。预发布环境应能累积多个可独立访问的运行,且替换范围仅限相同的运行 ID。
配套 PR
InferenceX PR #2412 会更新
/stage-results的请求确认与完成提示,使其准确说明运行持久化语义。验证
actionlint .github/workflows/stage-results.ymlbun run fmtbun run lintbun run typecheckbun run test:unit— 3,441 项测试通过Note
Medium Risk
Changes shared staging DB semantics (data persistence vs full reset) and keeps a destructive Neon restore path behind an explicit flag; ingest concurrency is unchanged.
Overview
Staging no longer wipes the Neon staging database on every
/stage-resultsingest. The job formerly namedrefresh-staging-databaseis nowprepare-staging-database: by default it skips the Neon restore and relies on idempotent, run-keyed ingestion so new runs accumulate and re-staging the same run ID only updates that run.Opt-in reset:
workflow_dispatchgains areset-staging-databaseboolean (defaultfalse). Whentrue, behavior matches the old path—restore staging from production before ingest—and validation passes the flag through job outputs. Thereportjob’s success gate andneedslist were updated for the renamed prepare job.Reviewed by Cursor Bugbot for commit 4170af0. Bugbot is set up for automated code reviews on this repo. Configure here.