Skip to content

fix: add retries to assisted installer API calls - #202

Open
tonykay wants to merge 1 commit into
mainfrom
fix/assisted-scale-api-retries
Open

fix: add retries to assisted installer API calls#202
tonykay wants to merge 1 commit into
mainfrom
fix/assisted-scale-api-retries

Conversation

@tonykay

@tonykay tonykay commented Aug 5, 2026

Copy link
Copy Markdown

Summary

  • Add retries/delay/until wrappers to 4 assisted installer API calls in host_ocp4_assisted_scale that previously had no retry logic: list_clusters, import_cluster, update_cluster, create_infra_env
  • Introduce configurable ai_api_retries (default 5) and ai_api_delay (default 30s) variables in role defaults, following the same pattern as existing approve_csr_retries/approve_csr_delay
  • wait_for_hosts already had retries and is unchanged

Motivation

Transient SSO invalid_grant errors during Red Hat token exchange cause the role to fail immediately at the first API call. With 5 retries × 30s delay, the role tolerates up to 2.5 minutes of SSO instability before failing.

Test plan

  • Deploy a CNV cluster that uses host_ocp4_assisted_scale and verify worker scaling completes
  • Verify overriding ai_api_retries / ai_api_delay in catalog item vars works as expected

🤖 Generated with Claude Code

…d_scale

The list_clusters, import_cluster, update_cluster, and create_infra_env
calls had no retry/until wrappers. A transient SSO "invalid_grant" error
during token exchange causes the entire role to fail immediately.

Adds configurable ai_api_retries (default 5) and ai_api_delay (default
30s) variables, consistent with the existing approve_csr_retries pattern.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@tonykay
tonykay requested a review from a team as a code owner August 5, 2026 21:30
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