operator
operator copied to clipboard
Add components and deprecate deployments
As per title.
Fixes #1155
Proposed Changes
- Add
spec.components - Deprecated
spec.deployments
Release Note
knativeeventing.spec.deployments and knativeserving.spec.deployments is deprecated, use knativeeventing.spec.components and knativeserving.spec.components instead.
TODO: change documentation in knative/docs
Codecov Report
Base: 79.21% // Head: 79.40% // Increases project coverage by +0.18% :tada:
Coverage data is based on head (
914456f) compared to base (16de0cb). Patch coverage: 84.37% of modified lines in pull request are covered.
Additional details and impacted files
@@ Coverage Diff @@
## main #1246 +/- ##
==========================================
+ Coverage 79.21% 79.40% +0.18%
==========================================
Files 35 35
Lines 1588 1602 +14
==========================================
+ Hits 1258 1272 +14
Misses 239 239
Partials 91 91
| Impacted Files | Coverage Δ | |
|---|---|---|
| pkg/reconciler/common/workload_override.go | 83.87% <83.87%> (ø) |
|
| pkg/reconciler/common/ha.go | 63.26% <100.00%> (ø) |
|
| pkg/reconciler/common/resources.go | 84.21% <100.00%> (ø) |
|
| pkg/reconciler/common/transformers.go | 85.71% <100.00%> (ø) |
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.
:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.
/cc @houshengbo @matzew
Per my comment here: https://github.com/knative/operator/issues/1155#issuecomment-1271740272 I will say do not deprecate the spec.deployment, at least in the current v1beta1 CRDs.
Once we have a new version of CRDs, we can deprecate the spec.deployment.
Per my comment here: #1155 (comment) I will say do not deprecate the spec.deployment, at least in the current v1beta1 CRDs.
Once we have a new version of CRDs, we can deprecate the spec.deployment.
Notifying of a deprecation earlier is naturally better, we're not breaking users and there is already the recommended option, why is that the approach that would be better in this case?
cc @houshengbo
if you feel strong about that I can just update the release notes to remove the deprecation warning
I'd say we add the deprecated warning, as a vehicle to communicate that things are changing, via the code
@matzew done!
LGTM. As a side note not sure why fetcher needs to run with hack/update-codegen.sh, I think it should only fetch new stuff if some upgrade flag is passed.
This PR needs to add more test coverage.
/unhold /lgtm /approve
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: houshengbo, matzew, pierDipi
The full list of commands accepted by this bot can be found here.
The pull request process is described here
- ~~OWNERS~~ [houshengbo,matzew]
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
/cherry-pick release-1.7
/cherry-pick release-1.6
/cherry-pick release-1.5
@matzew: #1246 failed to apply on top of branch "release-1.7":
Applying: Add components and deprecate deployments
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/reconciler/common/ha.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/ha.go
Removing pkg/reconciler/common/deployments_override.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Run update-codegen.sh
Applying: Lint error
Applying: Fix unit test
Applying: Add unit test for new field
Applying: Make common function more generic
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/reconciler/common/ha.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/ha.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Rename to workloads
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/reconciler/common/ha.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/ha.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Run update codegen
Applying: Rename ComponentsOverride -> Workloads
Applying: Test StatefulSet resource requirements
Applying: Run update-codegen.sh
Applying: Test StatefulSet transform
Applying: Update codegen again
Using index info to reconstruct a base tree...
M go.mod
Falling back to patching base and 3-way merge...
Auto-merging go.mod
CONFLICT (content): Merge conflict in go.mod
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0013 Update codegen again
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
In response to this:
/cherry-pick release-1.7
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
@matzew: #1246 failed to apply on top of branch "release-1.6":
Applying: Add components and deprecate deployments
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/reconciler/common/ha.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/ha.go
Removing pkg/reconciler/common/deployments_override.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Run update-codegen.sh
Applying: Lint error
Applying: Fix unit test
Applying: Add unit test for new field
Applying: Make common function more generic
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/reconciler/common/ha.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/ha.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Rename to workloads
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/reconciler/common/ha.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/ha.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Run update codegen
Applying: Rename ComponentsOverride -> Workloads
Applying: Test StatefulSet resource requirements
Applying: Run update-codegen.sh
Applying: Test StatefulSet transform
Applying: Update codegen again
Using index info to reconstruct a base tree...
M go.mod
Falling back to patching base and 3-way merge...
Auto-merging go.mod
CONFLICT (content): Merge conflict in go.mod
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0013 Update codegen again
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
In response to this:
/cherry-pick release-1.6
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
@matzew: #1246 failed to apply on top of branch "release-1.5":
Applying: Add components and deprecate deployments
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/apis/operator/base/common.go
M pkg/reconciler/common/ha.go
M pkg/reconciler/common/transformers.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/transformers.go
Auto-merging pkg/reconciler/common/ha.go
Removing pkg/reconciler/common/deployments_override.go
Auto-merging pkg/apis/operator/base/common.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Run update-codegen.sh
Applying: Lint error
Applying: Fix unit test
Applying: Add unit test for new field
Applying: Make common function more generic
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/apis/operator/base/common.go
M pkg/apis/operator/base/zz_generated.deepcopy.go
M pkg/reconciler/common/ha.go
M pkg/reconciler/common/transformers.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/transformers.go
Auto-merging pkg/reconciler/common/ha.go
Auto-merging pkg/apis/operator/base/zz_generated.deepcopy.go
Auto-merging pkg/apis/operator/base/common.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Rename to workloads
Using index info to reconstruct a base tree...
M config/crd/bases/operator.knative.dev_knativeeventings.yaml
M config/crd/bases/operator.knative.dev_knativeservings.yaml
M pkg/apis/operator/base/common.go
M pkg/apis/operator/base/zz_generated.deepcopy.go
M pkg/reconciler/common/ha.go
M pkg/reconciler/common/transformers.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/transformers.go
Auto-merging pkg/reconciler/common/ha.go
Auto-merging pkg/apis/operator/base/zz_generated.deepcopy.go
Auto-merging pkg/apis/operator/base/common.go
Auto-merging config/crd/bases/operator.knative.dev_knativeservings.yaml
Auto-merging config/crd/bases/operator.knative.dev_knativeeventings.yaml
Applying: Run update codegen
Applying: Rename ComponentsOverride -> Workloads
Applying: Test StatefulSet resource requirements
Using index info to reconstruct a base tree...
M pkg/reconciler/common/testdata/manifest.yaml
Falling back to patching base and 3-way merge...
Auto-merging pkg/reconciler/common/testdata/manifest.yaml
CONFLICT (content): Merge conflict in pkg/reconciler/common/testdata/manifest.yaml
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0010 Test StatefulSet resource requirements
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
In response to this:
/cherry-pick release-1.5
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.