Skip to content

feat(temporal): waitForArgoSync activity + argoSync profile (#106) - #192

Merged
lex00 merged 1 commit into
mainfrom
feat/temporal-argo-sync-106
Jun 4, 2026
Merged

lex00 merged 1 commit into
mainfrom
feat/temporal-argo-sync-106

Conversation

@lex00

@lex00 lex00 commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Part of #100. Closes #106.

A dependency-free Temporal activity that lets workflows gate procedural steps on a declarative apply that Argo owns.

waitForArgoSync(args, signal?, fetcher?)

  • Polls an Argo Application until health=Healthy && sync=Synced.
  • Primitives-only signature (appName / namespace / server / …) — imports neither the k8s lexicon nor the generated Argo CRD types.
  • Reads status via kubectl get application by default, or the Argo CD REST API when server is set.
  • Heartbeats every poll; fails fast with ArgoSyncFailedError on a terminal-unhealthy state (Degraded / Missing).
  • Status reader is injectable (fetcher) → unit-tested against a faked Argo API with Healthy/Progressing/Degraded transitions.

argoSync profile (TEMPORAL_ACTIVITY_PROFILES)

30m timeout, 60s heartbeat, cheap idempotent retries, ArgoSyncFailedError non-retryable.

Auto-registered with the generated worker via the activities barrel export.

Acceptance criteria

  • ✅ Unit test against a faked Argo API (Healthy/Progressing/Degraded).
  • ✅ argoSync profile exported + documented; signature primitives-only.
  • ⚠️ Integration test against a real Argo Application is an E2E (cluster-dependent) and not runnable in CI.

🤖 Generated with Claude Code

- waitForArgoSync({ appName, namespace?, server?, ... }) — a dependency-free
  activity (primitives-only signature; imports neither the k8s lexicon nor the
  generated Argo CRD types) that polls an Argo Application until
  health=Healthy && sync=Synced. Reads status via kubectl by default, or the
  Argo CD REST API when a server URL is given. Heartbeats every poll. Fails
  fast with ArgoSyncFailedError on a terminal-unhealthy state (Degraded/Missing).
  Status reader is injectable so it unit-tests against a faked Argo API.
- argoSync profile in TEMPORAL_ACTIVITY_PROFILES — 30m timeout, 60s heartbeat,
  cheap idempotent retries, ArgoSyncFailedError non-retryable.

Auto-registered with the generated worker via the activities barrel export.

Part of #100.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@lex00
lex00 merged commit 802e7cc into main Jun 4, 2026
@lex00
lex00 deleted the feat/temporal-argo-sync-106 branch June 4, 2026 22:25
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.

feat(temporal): waitForArgoSync activity + argoSync profile

1 participant