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

consistent label selector for Service - include app label #13265

Merged
merged 1 commit into from
Jan 13, 2023

Conversation

a7i
Copy link
Contributor

@a7i a7i commented Aug 31, 2022

Proposed Changes

  • components such as controller, autoscaler use the selector label app while webhook and domainmapping-webhook use the role selector. This change includes the app label which brings consistency across all resources.

Note and Service and PodDisruptionBudget selectors are not immutable, meaning that they can change (unlike Deployment/StatefulSet).

Release Note

Add `app` label to Service selector for `webhook` and `domainmapping-webhook`.

@knative-prow knative-prow bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Aug 31, 2022
@knative-prow
Copy link

knative-prow bot commented Aug 31, 2022

Welcome @a7i! It looks like this is your first PR to knative/serving 🎉

@knative-prow knative-prow bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Aug 31, 2022
@knative-prow
Copy link

knative-prow bot commented Aug 31, 2022

Hi @a7i. Thanks for your PR.

I'm waiting for a knative member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

@psschwei
Copy link
Contributor

Thanks for the PR!
/ok-to-test

@dprotaso any legacy reason why we preferred role over app for some components?

@knative-prow knative-prow bot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Aug 31, 2022
@codecov
Copy link

codecov bot commented Aug 31, 2022

Codecov Report

Base: 86.44% // Head: 86.47% // Increases project coverage by +0.02% 🎉

Coverage data is based on head (a1dbe09) compared to base (76005a0).
Patch has no changes to coverable lines.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #13265      +/-   ##
==========================================
+ Coverage   86.44%   86.47%   +0.02%     
==========================================
  Files         196      196              
  Lines       14600    14600              
==========================================
+ Hits        12621    12625       +4     
+ Misses       1678     1675       -3     
+ Partials      301      300       -1     
Impacted Files Coverage Δ
pkg/autoscaler/statserver/server.go 78.10% <0.00%> (+0.72%) ⬆️
pkg/reconciler/configuration/configuration.go 84.36% <0.00%> (+1.42%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@skonto
Copy link
Contributor

skonto commented Sep 6, 2022

The app label seems to be a requirement for istio telemetry. Also there is this issue #13168 that discusses avoiding using the label.

@dprotaso
Copy link
Member

dprotaso commented Nov 9, 2022

Also there is this issue #13168 that discusses avoiding using the label.

That's referring to the app label we're automatically adding to the revision pods/deployment.

I think role is just a legacy thing we don't need anymore - it looks like it was part of the initial commit

Copy link
Member

@dprotaso dprotaso left a comment

Choose a reason for hiding this comment

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

Let's make sure we have app in the selector and in a subsequent release we can drop the role label.

config/core/deployments/activator-hpa.yaml Outdated Show resolved Hide resolved
config/core/deployments/activator.yaml Outdated Show resolved Hide resolved
config/core/deployments/webhook-hpa.yaml Outdated Show resolved Hide resolved
@dprotaso
Copy link
Member

bump @a7i - you still interested in landing this PR?

@a7i a7i force-pushed the amir/service-selector branch from 8b79879 to a1dbe09 Compare January 13, 2023 18:34
@a7i a7i requested a review from dprotaso January 13, 2023 18:35
@a7i
Copy link
Contributor Author

a7i commented Jan 13, 2023

Let's make sure we have app in the selector and in a subsequent release we can drop the role label.

It's going to be tough to remove labels from Deployment selectors as they're immutable. It will require a forced recreate.

@dprotaso
Copy link
Member

It will require a forced recreate.

I see - then let's not worry about it then.

/lgtm
/approve

@knative-prow knative-prow bot added the lgtm Indicates that a PR is ready to be merged. label Jan 13, 2023
@knative-prow
Copy link

knative-prow bot commented Jan 13, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: a7i, dprotaso

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:

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

@knative-prow knative-prow bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 13, 2023
@knative-prow knative-prow bot merged commit 162b8fb into knative:main Jan 13, 2023
@a7i a7i deleted the amir/service-selector branch January 13, 2023 21:52
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. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants