-
Notifications
You must be signed in to change notification settings - Fork 157
Emit metric to track null build latency #337
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ImJasonH 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 |
Once this is in it's just a matter of creating an aggregation job and a testgrid config. ;) |
@adrcunha does this mean this PR can be submitted as-is? Is this really all that's necessary to start emitting metrics? 🤞 |
Yes, this PR is mostly done. But I would run |
@adrcunha Am I supposed to see the metric data in logs?
I don't see metrics data in logs when I run knative/serving's e2e-tests.sh either, but it's possible I'm just missing something. |
Yes. But don't set the environment variable, use the |
@adrcunha I'm apparently unable to run e2e tests locally now, with or without the flag. Getting:
(This happens on this branch, and on a fresh checkout from master) Any idea what I may have done to get into this state? I thought the script started from scratch each time, is it possible some of my local config has crept in somehow? Prow seems to be able to run the tests just fine. |
I thought #286 was closed, let me take a look. |
After rebasing to pick up the fix for #286 I ran
Am I supposed to see metrics in the logs? Or do metrics get sent somewhere during the test that I don't see? (Also, wow, the tests take 5 minutes now, that's kinda annoying) |
Hummm... They took 9s on an execution on 9/7... With #335 they took 190s... And then with #344 it went up to 300s.
My apologies, local runs shortcut the test execution, so |
The ugly hack above will be gone once knative/test-infra#120 is merged (and the vendored test-infra bumped again, of course). |
I messed up my reply because I edited it, and now I can't even find your
message... Ugh.
Setting `PROW_JOB_ID` won't work because then `kubetest` will try to fetch
a project fro boskos. That's why I updated the comment mentioning that you
have to comment lines 196-199 in `vendor/github.com/knative/test-infra/scripts/library.sh`.
…On Sun, Sep 16, 2018 at 2:40 PM, Jason Hall ***@***.***> wrote:
$ PROW_JOB_ID=foo ./test/e2e-tests.sh --emit-metrics
...
2018/09/16 17:39:41 main.go:759: --gcp-project is missing, trying to fetch a project from boskos.
(for local runs please set --gcp-project to your dev project)
2018/09/16 17:39:41 main.go:771: provider gke, will acquire project type gke-project from boskos
2018/09/16 17:39:41 main.go:307: Something went wrong: failed to prepare test environment: --provider=gke boskos failed to acquire project: Post http://boskos/acquire?type=gke-project&state=free&dest=busy&owner=: dial tcp: lookup boskos: no such host
Test subprocess exited with code 1
Test result code is 1
Passing --gcp-project=bar to the script fails with an unrecognized flag.
|
I patched your PR and ran the tests:
Your test is not emitting metrics. From what I understand, the tests are not setting up logging in https://github.com/knative/serving/blob/2291c782bc3ef9f84a2b7eb37db4f745cfac26fa/test/e2e_flags.go#L59 like in Line 40 in 8576fc7
|
I got this to work 🎉
/hold cancel |
/assign adrcunha |
/lgtm |
@adrcunha Looks like all that's left is testgrid configs, as mentioned in #337 (comment) Can you let me know when those are in and we'll have pretty graphs to 😍 over? |
Metrics are now live, details in knative/test-infra#186. |
* Emit metric to track null build latency * Emit metric to track null build latency * Support EMIT_METRICS in e2e-tests.sh * Attempt to set up metrics flags * Fix metric setup
* Emit metric to track null build latency * Emit metric to track null build latency * Support EMIT_METRICS in e2e-tests.sh * Attempt to set up metrics flags * Fix metric setup
Proposed Changes
TODO
I'm pretty sure there's more I need to do here, to get these metrics displayed at http://testgrid.knative.dev/knative-build -- like knative/serving has. I'm not sure if that change happens in this repo somehow/somewhere, or in whatever config powers testgrid. /cc @jessiezcc
Release Note
/hold