Conversation
…pha P3) Cloud-API task model: the controller submits stable keys derived from plan ID + task type + plan index. The sidecar owns execution lifecycle and transparently re-executes failed tasks on re-submit. Plan ID: - Each TaskPlan gets a uuid.New() at creation, stored in TaskPlan.ID. - DeterministicTaskID signature changes from (nodeName, taskType, attempt) to (planID, taskType, planIndex). Same plan = same IDs. New plan = new IDs. Simplified retry: - retryTask function deleted. On ExecutionFailed with retries remaining, the executor resets task status to Pending (same ID) and requeues. The sidecar's status-aware Submit handles re-execution transparently. Failure diagnostics: - TaskPlan gains FailedTaskIndex (*int) and FailedTaskDetail (*FailedTaskInfo) for operator triage without inspecting the full task list. - failTask records both fields before marking the plan as Failed. - Works for both SeiNode and SeiNodeGroup (both carry *TaskPlan). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
ddac8f8 to
0ece2b3
Compare
2 tasks
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
Cloud-API model for task lifecycle: the controller submits stable keys and the sidecar owns execution lifecycle. Companion to sei-protocol/seictl#61.
Changes
uuid.New()generated at plan creation. Task IDs derived fromDeterministicTaskID(planID, taskType, planIndex). Unique across rebuilds, stable within a plan.retryTaskdeleted — on failure with retries remaining, the executor resets task status to Pending with the same ID and requeues. The sidecar transparently re-executes failed tasks.FailedTaskIndexandFailedTaskDetailonTaskPlanrecord which task failed, its error, retry count, and max retries. Works for both SeiNode and SeiNodeGroup.DeterministicTaskIDrefactored — signature(planID, taskType, planIndex)replaces(nodeName, taskType, attempt). All 8 call sites updated.Design doc
Full implementation brief included at
docs/design-alpha-phase3-implementation.md.What this does NOT include (deferred)
sei.io/retry-planannotation — dropped from alpha scopetask_eventshistory table in sidecarTest plan
TestExecutePlan_RetryOnFailure— task ID stable on retry, RetryCount incrementedTestExecutePlan_ExhaustedRetries_FailsPlan— FailedTaskIndex and FailedTaskDetail recordedTestExecuteGroupPlan_CompletesSuccessfully— plan-based IDs work for group plansTestBuildPlan_UniqueIDsAcrossRebuilds— different plan IDs produce different task IDsTestBuildGroupAssemblyPlan_UniqueIDsAcrossRebuilds— same for group plansmake testgreen🤖 Generated with Claude Code