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

should propagation time include action #191

Open
lahabana opened this issue Jun 14, 2024 · 2 comments
Open

should propagation time include action #191

lahabana opened this issue Jun 14, 2024 · 2 comments
Labels
triage/accepted The issue was reviewed and is complete enough to start working on it

Comments

@lahabana
Copy link
Contributor

At the moment we wait for pods to be available (or policy to be applied) before computing the propagation time.

err := k8s.RunKubectlE(
cluster.GetTesting(),
cluster.GetKubectlOptions(TestNamespace),
"scale", "statefulset", observable, fmt.Sprintf("--replicas=%d", replicas),
)
Expect(err).ToNot(HaveOccurred())
err = cluster.Install(WaitNumPods(TestNamespace, replicas, observable))
Expect(err).ToNot(HaveOccurred())
propagationStart := time.Now()
Eventually(func(g Gomega) {
membership, err := admin.GetStats(fmt.Sprintf("cluster.%s_kuma-test_svc_80.membership_total", observable))
g.Expect(err).ToNot(HaveOccurred())
g.Expect(membership.Stats[0].Value).To(BeNumerically("==", replicas))
}, "60s", "1s").Should(Succeed())
AddReportEntry("endpoint_propagation_duration", time.Since(propagationStart).Milliseconds())

Should we include that time?
If we do we'll be sensitive of the time it takes to start a pod so platform dependent. However, this is a stat that's more useful to users than what we have today.

Another option is to watch for change to endpointSlice and count from there. This would sum up as "how much longer does it take for an endpoint to be added compared to core k8s" though that wouldn't even be exact...

@github-actions github-actions bot added the triage/pending This issue will be looked at on the next triage meeting label Jun 14, 2024
@lobkovilya
Copy link
Contributor

Triage: regardless of the approach we pick using WaitNumPods is not accurate enough as it's using a loop with sleeps. Probably we should watch an endpointSlice and start the timer when the endpoint is added.

@lobkovilya lobkovilya added triage/accepted The issue was reviewed and is complete enough to start working on it and removed triage/pending This issue will be looked at on the next triage meeting labels Jun 17, 2024
@github-actions github-actions bot added the triage/stale Inactive for some time. It will be triaged again label Sep 16, 2024
Copy link
Contributor

This issue was inactive for 90 days. It will be reviewed in the next triage meeting and might be closed.
If you think this issue is still relevant, please comment on it or attend the next triage meeting.

@slonka slonka removed the triage/stale Inactive for some time. It will be triaged again label Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage/accepted The issue was reviewed and is complete enough to start working on it
Projects
None yet
Development

No branches or pull requests

3 participants