Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cherry-pick #361 and master flake fixes to release-0.13 #362

Closed

Conversation

annasong20
Copy link
Contributor

@annasong20 annasong20 commented Nov 28, 2023

What this PR does / why we need it:

This PR cherry-picks #361 to the release-0.13 branch. Because the current release-0.13 branch doesn't have the commits that fix the flaky tests, this PR also cherry-picks all commits up to 8f5c459.

This PR allows users to consume #361 in environments that cannot update their sigs.k8s.io/controller-runtime version past v0.15.0.

Additional information

I didn't create this PR against release-0.15 branch because the tip of that branch is on v0.15.2 of sigs.k8s.io/controller-runtime, which my environment cannot update to yet.

justinsb and others added 30 commits November 9, 2022 14:36
Not doing so makes it harder to build options outside of the call,
because we can't declare a []reconcilerOption unless it is exported.
The SMD library has a lot of the logic of server-side-apply (and
more!) that we can reuse here.

Co-authored-by: Antoine Pelisse <apelisse@gmail.com>
Generated using makefile, which extracts it from the k/k repo.
This enables us to test full controllers very easily, including the
exact requests we make.
…ller

Create test reconciler and capture http requests
mockkubeapiserver: add test using SMD library
We now get status updates and fieldmanagers in our mockkubeapiserver tests!
In theory a breaking change, but should not break anyone and avoids
reparsing and confusion over JSON vs YAML input formats.
We generate a metadata file that includes the additional type
information we need.
Co-authored-by: Justin Santa Barbara <justinsb@google.com>
We lost the default value in kubernetes-sigs#247, which is a regression that prevents
some changes from going through.
…_strings

Change ApplierOptions to take Objects, not a manifest.
As of Go 1.16, funcs related to operate files and directories in the
ioutil pakage are deprecated.

This commit replaces deprecated funcs on ioutil by using io and os
packages.
…d-ioutil-funcs

Replace deprecated funcs on ioutil package
justinsb and others added 11 commits June 26, 2023 16:26
commonclient contains wrappers around functions we use from
controller-runtime which have changed between 0.11 and 0.15 (the version
range we are supporting currently).

This allows for buildtags to be used to select a previous version of
controller-runtime, without needing to carry patches.
Create abstraction layer over controller-runtime/client-go versions
A comparable change is being made in kubectl also; kind is clearer for
end-users, and this enables creation of a CRD and an instance of the
CRD in one applyset.
applyset: Switch to contains-group-kinds annotation
As suggested in prior code review.
Cleanup: remove commented-out code in kubectl fork
move applylib/third_party/forked to applylib/forked
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Nov 28, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: annasong20
Once this PR has been reviewed and has the lgtm label, please assign atoato88 for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Nov 28, 2023
Remove extra newlines between objects in test/validator manifest output.
@k8s-ci-robot k8s-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Nov 29, 2023
@annasong20 annasong20 changed the title Cherry-pick Validator output spacing #361 Cherry-pick #361 and master flake fixes to release-0.13 Nov 29, 2023
@yuwenma
Copy link
Contributor

yuwenma commented Nov 29, 2023

/lgtm

Thank you, Anna.

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Nov 29, 2023
@annasong20
Copy link
Contributor Author

/cc @haiyanmeng

@annasong20
Copy link
Contributor Author

/close

After discussion with @yuwenma, @justinsb, we've decided to close this PR in favor of adding

//go:build

comments to make the master branch backwards compatible with previous versions of controller-runtime.

@k8s-ci-robot
Copy link
Contributor

@annasong20: Closed this PR.

In response to this:

/close

After discussion with @yuwenma, @justinsb, we've decided to close this PR in favor of adding

//go:build

comments to make the master branch backwards compatible with previous versions of controller-runtime.

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.

@annasong20 annasong20 deleted the pick-newline-commit branch November 30, 2023 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet