Skip to content

Conversation

@topshihun
Copy link
Contributor

No description provided.

Signed-off-by: Wangyan <topshihun@foxmail.com>
@topshihun topshihun force-pushed the feat/task-auto-retry branch from c84b191 to 3fb3775 Compare January 5, 2026 14:05
@topshihun topshihun changed the title feat: Auto retry judge and build feat(orion-server): Auto retry judge and build Jan 5, 2026
@genedna
Copy link
Member

genedna commented Jan 5, 2026

@codex review

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR implements an automatic retry mechanism for build tasks in the orion-server. It introduces logic to determine whether a failed build should be automatically retried based on exit codes (signal interruptions) or output keywords (network/HTTP errors), with a maximum of 3 retry attempts per build.

Key Changes:

  • New AutoRetryJudger component to evaluate retry eligibility based on exit codes (129-191 range for signal interruptions) and output patterns (HTTP/network-related keywords)
  • Added retry_time field to track retry attempts in the builds database model
  • Modified build completion flow to conditionally retry tasks before marking them as complete

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 12 comments.

Show a summary per file
File Description
orion-server/src/auto_retry.rs New module implementing retry decision logic with exit code and output-based heuristics, including comprehensive tests
orion-server/src/api.rs Integrates retry judger into message processing, adds retry loop for output analysis, and implements retry dispatch logic in BuildComplete handler
orion-server/src/scheduler.rs Extends BuildInfo struct with auto_retry_judger and retry_time fields, initializes them during build creation
orion-server/src/model/builds.rs Adds retry_time database column to track retry attempts
orion-server/src/main.rs Registers auto_retry module
orion-server/src/lib.rs Exports auto_retry module publicly
orion-server/Cargo.toml Adds once_cell dependency for OnceCell usage
orion/src/api.rs Documents that BuildResult's exit_code and can_auto_retry fields contain invalid data during immediate acknowledgment

Copy link

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

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: 3fb3775dae

ℹ️ 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".

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: TOP <89700178+topshihun@users.noreply.github.com>
Signed-off-by: Wangyan <topshihun@foxmail.com>
@genedna
Copy link
Member

genedna commented Jan 6, 2026

@codex review

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 11 comments.

Copy link

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

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: 2eeb2ad92e

ℹ️ 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".

@topshihun topshihun changed the title feat(orion-server): Auto retry judge and build feat: Auto retry judge and build Jan 6, 2026
@topshihun topshihun force-pushed the feat/task-auto-retry branch from 1312820 to a8a3594 Compare January 6, 2026 11:06
Signed-off-by: Wangyan <topshihun@foxmail.com>
@topshihun topshihun force-pushed the feat/task-auto-retry branch from a8a3594 to e14f1c7 Compare January 6, 2026 11:34
Signed-off-by: Wangyan <topshihun@foxmail.com>
@topshihun topshihun force-pushed the feat/task-auto-retry branch from e14f1c7 to c75ef2a Compare January 6, 2026 11:36
@benjamin-747 benjamin-747 added this pull request to the merge queue Jan 6, 2026
Merged via the queue into web3infra-foundation:main with commit 48fc759 Jan 6, 2026
5 checks passed
lvy010 pushed a commit to lvy010/mega that referenced this pull request Jan 7, 2026
* feat: auto retry time

Signed-off-by: Wangyan <topshihun@foxmail.com>

* Update orion-server/src/auto_retry.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: TOP <89700178+topshihun@users.noreply.github.com>

* fix: clippy and other advices

Signed-off-by: Wangyan <topshihun@foxmail.com>

---------

Signed-off-by: Wangyan <topshihun@foxmail.com>
Signed-off-by: TOP <89700178+topshihun@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
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.

3 participants