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

Wait for updated keys to be observed #128966

Merged
merged 1 commit into from
Nov 25, 2024

Conversation

liggitt
Copy link
Member

@liggitt liggitt commented Nov 25, 2024

What type of PR is this?

/kind cleanup
/kind failing-test
/kind flake

What this PR does / why we need it:

Waits for the metric indicating keys have been observed to be incremented.

This matches how external integrations would detect update of keys as well.

Which issue(s) this PR fixes:

Fixes #128871

Does this PR introduce a user-facing change?

NONE

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. kind/failing-test Categorizes issue or PR as related to a consistently or frequently failing test. kind/flake Categorizes issue or PR as related to a flaky test. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Nov 25, 2024
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If a SIG or subproject determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

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-ci-robot k8s-ci-robot added the needs-priority Indicates a PR lacks a `priority/foo` label and requires one. label Nov 25, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: liggitt

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

@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. area/test sig/testing Categorizes an issue or PR as relevant to SIG Testing. and removed do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Nov 25, 2024
@@ -235,6 +238,36 @@ func TestExternalJWTSigningAndAuth(t *testing.T) {
}
}

func waitForDataTimestamp(t *testing.T, client kubernetes.Interface, minimumDataTimestamp time.Time) {
Copy link
Member Author

Choose a reason for hiding this comment

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

output of running this:

go test ./test/integration/serviceaccount -run TestExternalJWTSigningAndAuth/after_periodic_sync -v -count=1 | grep _test.go
    external_jwt_signer_test.go:220: waiting for >=1732553885.155639
    external_jwt_signer_test.go:260: apiserver_externaljwt_fetch_keys_data_timestamp at 1732553885.000000, waiting until >=1732553885.155639...
    external_jwt_signer_test.go:260: apiserver_externaljwt_fetch_keys_data_timestamp at 1732553885.000000, waiting until >=1732553885.155639...
    external_jwt_signer_test.go:260: apiserver_externaljwt_fetch_keys_data_timestamp at 1732553885.000000, waiting until >=1732553885.155639...
    external_jwt_signer_test.go:260: apiserver_externaljwt_fetch_keys_data_timestamp at 1732553885.000000, waiting until >=1732553885.155639...
    external_jwt_signer_test.go:260: apiserver_externaljwt_fetch_keys_data_timestamp at 1732553885.000000, waiting until >=1732553885.155639...
    external_jwt_signer_test.go:263: saw 1732553890.000000

Copy link
Member Author

Choose a reason for hiding this comment

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

follow-up for 1.33 in #128967 to actually record the data timestamp from the external signer as a float instead of truncating to seconds

@liggitt
Copy link
Member Author

liggitt commented Nov 25, 2024

/skip

@liggitt
Copy link
Member Author

liggitt commented Nov 25, 2024

/assign @enj @ahmedtd
/cc @HarshalNeelkamal

@k8s-ci-robot
Copy link
Contributor

@liggitt: GitHub didn't allow me to request PR reviews from the following users: HarshalNeelkamal.

Note that only kubernetes members and repo collaborators can review this PR, and authors cannot review their own PRs.

In response to this:

/assign @enj @ahmedtd
/cc @HarshalNeelkamal

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-ci-robot
Copy link
Contributor

k8s-ci-robot commented Nov 25, 2024

@liggitt: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-kubernetes-linter-hints 26c08dd link false /test pull-kubernetes-linter-hints

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@liggitt
Copy link
Member Author

liggitt commented Nov 25, 2024

/retest

@deads2k
Copy link
Contributor

deads2k commented Nov 25, 2024

I think I get it. This looks significantly more reliable.

/lgtm

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

LGTM label has been added.

Git tree hash: a3225738c77d53e6698371d93b23d5ee4f75e9cd

@deads2k
Copy link
Contributor

deads2k commented Nov 25, 2024

/milestone v1.32

@k8s-ci-robot k8s-ci-robot added this to the v1.32 milestone Nov 25, 2024
@k8s-ci-robot k8s-ci-robot merged commit 8770bd5 into kubernetes:master Nov 25, 2024
15 checks passed
@liggitt liggitt deleted the deflake-external branch December 13, 2024 12:49
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. area/test cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. kind/failing-test Categorizes issue or PR as related to a consistently or frequently failing test. kind/flake Categorizes issue or PR as related to a flaky test. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. release-note-none Denotes a PR that doesn't merit a release note. sig/testing Categorizes an issue or PR as relevant to SIG Testing. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Flaking Test] integration TestExternalJWTSigningAndAuth
5 participants