Skip to content

CH-302 feat: Add optional async workflow submission timeout - #899

Merged
filippomc merged 2 commits into
developfrom
Feature/CH-302
Nov 12, 2026
Merged

filippomc merged 2 commits into
developfrom
Feature/CH-302

Conversation

@afonsobspinto

@afonsobspinto afonsobspinto commented Nov 11, 2026 •

Copy link
Copy Markdown
Member

Closes CH-302

Problem

AsyncOperation.execute() waits for Argo to acknowledge workflow creation. A stalled Argo response can leave the calling API request waiting indefinitely and keep any database row lock held by the caller. A configurable timeout lets callers limit that wait through the Cloud Harness API.

Change

Add an optional request_timeout to argo_service.submit_workflow(). AsyncOperation.execute() and ContainerizedOperation.submit() forward submission options to that service.

workflow = operation.execute(request_timeout=(2, 10))

The Argo SDK accepts a timeout in seconds or a (connect, read) tuple for the HTTP create request. Cloud Harness closes the HTTP client on success or failure, propagates submission errors, and makes one submission attempt per call. Argo may accept a workflow before the response times out, so callers should check whether it was created before retrying.

Validation

  • The original commits passed common-library, model, deployment CLI, and Argo component CI, plus lint and CodeQL.
  • 54 SDK and workflow tests passed, covering legacy calls, numeric and tuple timeouts, the returned Workflow wrapper, one POST per call, and client cleanup.
  • A regression test with a stalled local HTTP server verified that execute() times out after one CREATE attempt and allows the caller to reconcile the outcome.

Supersedes #897.

@filippomc
filippomc merged commit d9e8cde into develop Nov 12, 2026
9 of 11 checks passed
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.

2 participants