|
| 1 | +# GA API shape — review copies |
| 2 | + |
| 3 | +These are the complete Go API type definitions for ClusterObjectDeployment, |
| 4 | +ClusterObjectSet, and ClusterExtension (plus the shared condition constants in |
| 5 | +`common_types.go`), copied from the `refactor/clusterobjectset-status-api` branch. |
| 6 | +They are copied here so the proposed GA shape can be reviewed in its entirety |
| 7 | +rather than as a diff against the current types. |
| 8 | + |
| 9 | +This directory is for review only and will not be merged. The files are otherwise |
| 10 | +unmodified; they rely only on the unchanged `groupversion_info.go` boilerplate. |
| 11 | +Channel-specific descriptions are marked with `<opcon:standard:...>` and |
| 12 | +`<opcon:experimental:...>` directives; CRD schemas, printer columns, and |
| 13 | +validation are generated from the kubebuilder markers shown here. |
| 14 | + |
| 15 | +## Differences from the current upstream/main experimental CRDs |
| 16 | + |
| 17 | +Note: "removed" below means the field is not part of the proposed standard GA |
| 18 | +API, or is not relevant under the `BoxcutterRuntime` feature gate — not |
| 19 | +necessarily that the capability is gone from the product. |
| 20 | + |
| 21 | +### ClusterObjectDeployment (`clusterobjectdeployment_types.go`) |
| 22 | + |
| 23 | +- Removed `spec.progressDeadlineMinutes` and the `ProgressDeadlineExceeded` |
| 24 | + Progressing reason. |
| 25 | +- `Available` redefined around per-object probe health instead of revision |
| 26 | + readiness: True when any active, non-deleting, owned revision reports |
| 27 | + `presentObjects == totalObjects` and `healthyObjects == presentObjects`; |
| 28 | + reasons `Available`, `Unavailable`, `Unknown`, `NoActiveRevision`. |
| 29 | +- `status.conditions` documentation restructured per Progressing reason, without |
| 30 | + controller internals; `NewClusterObjectSetProgressing` now also covers revision |
| 31 | + creation and adoption. |
| 32 | +- `spec.template.metadata` documents its reserved labels |
| 33 | + (`olm.operatorframework.io/template-hash`, `app.kubernetes.io/managed-by`) and |
| 34 | + the label/annotation entry limits and validation. |
| 35 | + |
| 36 | +### ClusterObjectSet (`clusterobjectset_types.go`) |
| 37 | + |
| 38 | +- Object sources: `secretRef` (Secret reference) replaced by `objectSliceRef` |
| 39 | + (name + key into a cluster-scoped `ClusterObjectSlice`, whose CRD is provided |
| 40 | + externally and is not included here); the object `type` enum is now |
| 41 | + `InlineManifest`/`ObjectSliceRef`. |
| 42 | +- Probes: revision-level `progressionProbes` (selector + |
| 43 | + `ConditionEqual`/`FieldsEqual`/`FieldValue` assertions) replaced by per-object |
| 44 | + `progressionProbes` supporting `ConditionEqual` and `CEL` rules. |
| 45 | +- Status counts: `status.objectCounts.{total,present,synced,ready}` replaced by |
| 46 | + top-level `totalObjects`, `presentObjects`, `syncedObjects`, `healthyObjects`, |
| 47 | + `unhealthyObjects` (new), `supersededObjects`, and `collidingObjects`; |
| 48 | + `unhealthyObjects` distinguishes failed probes from undetermined ones. |
| 49 | +- `status.observedPhases` replaced by `status.phases`: pinned `contentDigest`, |
| 50 | + lifecycle `status`, machine-readable `reason`, and sparse per-object |
| 51 | + `diagnostics` categorized by reason. |
| 52 | +- `spec.lifecycleState` documentation updated to assign archival responsibility: |
| 53 | + the owning ClusterObjectDeployment decides when to archive older revisions (on |
| 54 | + recorded rollout completion), the ClusterObjectSet controller tears down a |
| 55 | + revision once `lifecycleState` is set to `Archived`, and standalone callers |
| 56 | + archive explicitly. |
| 57 | +- New printer columns: `Unhealthy`, `Superseded`, `Colliding`. |
| 58 | + |
| 59 | +### ClusterExtension (`clusterextension_types.go`) |
| 60 | + |
| 61 | +- `spec.namespace` is optional at GA: when omitted, operator-controller |
| 62 | + resolves and creates a managed namespace from the bundle's metadata. Whether |
| 63 | + namespace is set or omitted is fixed at creation time; the value itself is |
| 64 | + immutable and DNS-label validated. (The standard CRD previously required it.) |
| 65 | +- Removed `spec.config` (inline bundle configuration), |
| 66 | + `spec.progressDeadlineMinutes`, and `status.install.bundle.release`. |
| 67 | +- Conditions documentation: the `Available` condition mirrors the managing |
| 68 | + ClusterObjectDeployment's `Available` condition. |
| 69 | + |
| 70 | +The only other change is the `controller-gen.kubebuilder.io/version` annotation |
| 71 | +(v0.21.0 → v0.23.0), from regenerating with the current toolchain. |
| 72 | + |
| 73 | +To reproduce a full diff for a kind: |
| 74 | + |
| 75 | +```console |
| 76 | +git diff upstream/main:api/v1/<kind>_types.go tmp/<kind>_types.go |
| 77 | +``` |
0 commit comments