Skip to content

[TASK] Refactor read the Orchestrator status contract from the operator's api/v1alpha1 #1769

Closed

Description

@edenreich

Summary

Operator v0.33.0 exports the Orchestrator status contract from api/v1alpha1 (inference-gateway/operator#322): OrchestratorConditionReady, a Reason* constant for every reason the controller sets on it, and AgentsDoneMessage. Each reason's doc comment says whether it clears on its own or needs a change to the spec or the cluster.

The Kubernetes workspace adapter in internal/agent/infrastructure/kubernetes still copies them as literals, so a renamed value in the operator breaks it without a compile error:

  • workspace.go, readyCondition: compares the condition type with "Ready".
  • workspace.go, unrecoverableReasons: "SandboxCRDMissing" and "InvalidSpec", the reasons a teleport fails fast on.
  • self.go, ReportIdle: writes "agents-done=" + strconv.FormatBool(done), which the operator matches against AgentsDoneMessage.

Importing github.com/inference-gateway/operator/api/v1alpha1 costs about 0.9MB in the stripped binary and adds sigs.k8s.io/gateway-api/apis/v1 and k8s.io/api/autoscaling/v2, measured for the operator issue. The package keeps controller-runtime out. Building the Orchestrator from the typed struct instead of an untyped map is out of scope.

Acceptance Criteria

  • The adapter reads the condition type and the fail-fast reasons from the operator's exported constants, with no copied literal left.
  • ReportIdle writes AgentsDoneMessage when every agent is done.
  • go.mod requires the operator module at v0.33.0 or newer, imported under an explicit alias.
  • The fail-fast list matches the reasons whose doc comment says they need a spec or cluster change.

Activity

  1. added
    refactor
    on Nov 8, 2026
  2. added theissue type on Nov 8, 2026
  3. moved this to Todo in 2026on Nov 8, 2026
  4. moved this from Todo to In progress in 2026on Nov 8, 2026
  5. moved this from In progress to QA in 2026on Nov 8, 2026
  6. moved this from QA to Done in 2026on Nov 8, 2026
  7. inference-gateway-releaser commented on Nov 9, 2026

    @inference-gateway-releaser
    Contributor

    🎉 This issue has been resolved in version 0.250.0 🎉

    The release is available on:

    Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    refactorreleased

    Type

    Projects

    • Status
      Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions