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

Use worker DS OwnerReference for NF's #1755

Merged
merged 2 commits into from
Jul 9, 2024

Conversation

ArangoGutierrez
Copy link
Contributor

No description provided.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jul 3, 2024
@k8s-ci-robot k8s-ci-robot requested a review from TessaIO July 3, 2024 14:19
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 3, 2024
Copy link

netlify bot commented Jul 3, 2024

Deploy Preview for kubernetes-sigs-nfd ready!

Name Link
🔨 Latest commit e33e68a
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-sigs-nfd/deploys/668d3654fff61f0008d38c49
😎 Deploy Preview https://deploy-preview-1755--kubernetes-sigs-nfd.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@ArangoGutierrez
Copy link
Contributor Author

/assign @marquiz

@ArangoGutierrez ArangoGutierrez force-pushed the 1752 branch 2 times, most recently from 5594d1e to 2db6bca Compare July 4, 2024 07:31
@ArangoGutierrez ArangoGutierrez requested a review from tariq1890 July 4, 2024 07:31
Copy link
Contributor

@adrianchiris adrianchiris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Signed-off-by: Carlos Eduardo Arango Gutierrez <[email protected]>
pkg/nfd-worker/nfd-worker.go Outdated Show resolved Hide resolved
pkg/nfd-worker/nfd-worker.go Show resolved Hide resolved
pkg/nfd-worker/nfd-worker.go Outdated Show resolved Hide resolved
@marquiz
Copy link
Contributor

marquiz commented Jul 5, 2024

/test pull-node-feature-discovery-verify-master

@ArangoGutierrez ArangoGutierrez requested a review from marquiz July 5, 2024 13:23
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 5, 2024
@marquiz
Copy link
Contributor

marquiz commented Jul 8, 2024

/test pull-node-feature-discovery-verify-master

@k8s-infra-cherrypick-robot

@ArangoGutierrez: once the present PR merges, I will cherry-pick it on top of release-0.15 in a new PR and assign it to you.

In response to this:

/cherry-pick release-0.15

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-sigs/prow repository.

@marquiz
Copy link
Contributor

marquiz commented Jul 9, 2024

/cherry-pick release-0.16

@k8s-infra-cherrypick-robot

@marquiz: once the present PR merges, I will cherry-pick it on top of release-0.16 in a new PR and assign it to you.

In response to this:

/cherry-pick release-0.16

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-sigs/prow repository.

pkg/nfd-worker/nfd-worker.go Outdated Show resolved Hide resolved
pkg/nfd-worker/nfd-worker.go Outdated Show resolved Hide resolved
pkg/nfd-worker/nfd-worker.go Outdated Show resolved Hide resolved
pkg/nfd-worker/nfd-worker.go Outdated Show resolved Hide resolved
@@ -761,7 +816,7 @@ func (m *nfdWorker) updateNodeFeatureObject(labels Labels) error {
nfrUpdated := nfr.DeepCopy()
nfrUpdated.Annotations = map[string]string{nfdv1alpha1.WorkerVersionAnnotation: version.Get()}
nfrUpdated.Labels = map[string]string{nfdv1alpha1.NodeFeatureObjNodeNameLabel: nodename}
nfrUpdated.OwnerReferences = ownerRefs
nfrUpdated.OwnerReferences = m.ownerReference
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ArangoGutierrez question regarding L825. if no change to NF spec will it still update the object to set owner reference ? just want to make sure that if we update NFD in the cluster (e.g helm upgrade -n ....), owner reference will be added to existing NF CRs.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DeepEqual evaluates the entire object, so the answer is yes, if this is a new pod, because XYZ reason, we would update the NF with the new ownerRef (if this changed)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it updates the object if anything changes (including the object metadata)

Copy link
Contributor

@adrianchiris adrianchiris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small question otherwise code LGTM

@ArangoGutierrez
Copy link
Contributor Author

/test pull-node-feature-discovery-e2e-test-master

Copy link
Contributor

@marquiz marquiz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job @ArangoGutierrez. I think this is good to go

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 9, 2024
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 46d9fb78c5d2143815a0d5ee50474aceceabf9a3

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: adrianchiris, ArangoGutierrez, marquiz

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

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [ArangoGutierrez,marquiz]

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

Signed-off-by: Carlos Eduardo Arango Gutierrez <[email protected]>
@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 9, 2024
@k8s-ci-robot k8s-ci-robot requested a review from marquiz July 9, 2024 13:08
@marquiz
Copy link
Contributor

marquiz commented Jul 9, 2024

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 9, 2024
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: aa0dc2aef50785e014d9be9f510e2b09da19b244

@k8s-ci-robot k8s-ci-robot merged commit 393af96 into kubernetes-sigs:master Jul 9, 2024
10 checks passed
@k8s-infra-cherrypick-robot

@ArangoGutierrez: #1755 failed to apply on top of branch "release-0.15":

Applying: Use worker DS OwnerReference for NF's
Applying: Add optionable arguments to NewWorker
Using index info to reconstruct a base tree...
M	cmd/nfd-worker/main.go
M	pkg/nfd-worker/nfd-worker-internal_test.go
M	pkg/nfd-worker/nfd-worker.go
M	pkg/nfd-worker/nfd-worker_test.go
M	test/e2e/utils/rbac.go
Falling back to patching base and 3-way merge...
Auto-merging test/e2e/utils/rbac.go
Auto-merging pkg/nfd-worker/nfd-worker_test.go
Auto-merging pkg/nfd-worker/nfd-worker.go
CONFLICT (content): Merge conflict in pkg/nfd-worker/nfd-worker.go
Auto-merging pkg/nfd-worker/nfd-worker-internal_test.go
Auto-merging cmd/nfd-worker/main.go
CONFLICT (content): Merge conflict in cmd/nfd-worker/main.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0002 Add optionable arguments to NewWorker
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-0.15

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-sigs/prow repository.

@k8s-infra-cherrypick-robot

@marquiz: new pull request created: #1771

In response to this:

/cherry-pick release-0.16

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-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. 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/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants