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

Add time it takes to build a kit in the builder pod log #1186

Closed
davsclaus opened this issue Jan 10, 2020 · 8 comments
Closed

Add time it takes to build a kit in the builder pod log #1186

davsclaus opened this issue Jan 10, 2020 · 8 comments
Milestone

Comments

@davsclaus
Copy link
Contributor

When build a kit it takes many minutes. It would be good to have that logged so we can see how long it takes. The logs dont have timestamps. But we can add a log entry in the start.

Building kit XXX starting
Building kit XXX completed in 4m17s

@davsclaus
Copy link
Contributor Author

Ah you can see that as they are a build job and you can get the duration from k8s

❯ kubectl get builds -n mykamel
NAME PHASE AGE STARTED DURATION ATTEMPTS
kit-boc0gekj6qtqprh6d5s0 Succeeded 29m 29m 3m57.766320235s
kit-boc0m8kj6qtqprh6d5sg Succeeded 16m 16m 4m37.372446786s

@nicolaferraro nicolaferraro added this to the 1.0.0-RC2 milestone Jan 10, 2020
@nicolaferraro nicolaferraro modified the milestones: 1.0.0-RC2, 1.0.0-future Feb 20, 2020
@nicolaferraro nicolaferraro modified the milestones: 1.0.0, post 1.0.0 May 26, 2020
@lburgazzoli
Copy link
Contributor

the builds time is from the OpenShift s2i build so I guess it would be nice to report the time on the kits themselves so you know how long it took for a kit to be build regardless of the build engine used

@astefanutti
Copy link
Member

Note the Camel builds resources already report the build duration irrespective of the builder strategy.

@lburgazzoli
Copy link
Contributor

oh right, so I guess I can close my PR right ?

@lburgazzoli
Copy link
Contributor

or maybe not as builds may get evicted / pruned in the future

@astefanutti
Copy link
Member

Yes, I would be inclined not to duplicate the info into the kit CR. Even if builds get evicted, I think it's more a transient info w.r.t. to kits, and its value decreases long before the build would be evicted.

@lburgazzoli
Copy link
Contributor

let me close the PR then

@lburgazzoli
Copy link
Contributor

We can achieve this by:

oc get builds.camel.apache.org

Which returns something like:

NAME                       PHASE       AGE   STARTED   DURATION         ATTEMPTS
kit-brgdaqjd9mqi280ama3g   Succeeded   56m   56m       2m8.590289934s   
kit-brgdc6jd9mqi280ama40   Error       53m   51m       2.851016382s     5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants