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

Convenience variables for time #405

Open
jessesuen opened this issue Feb 12, 2020 · 3 comments
Open

Convenience variables for time #405

jessesuen opened this issue Feb 12, 2020 · 3 comments
Labels
analysis Related to Analysis CRD enhancement New feature or request

Comments

@jessesuen
Copy link
Member

jessesuen commented Feb 12, 2020

DataDog requires some time information as part of it's queries:

https://docs.datadoghq.com/api/?lang=bash#query-timeseries-points

Rollouts should provide some convenience variables so that the deployment times can be passed to the query to the metric provider. The caveat is that the time format which DataDog wants the time to be in is in unix epoch, which is different than what other metric providers might want.

Recently we added {{experiment.availableAt}} and {{experiment.finishedAt}}, but:

  1. we need more (e.g. {{rollout.deployedAt}}, {{analysis.startedAt}})
  2. provide ways to convert the time into other formats that a metric provider wants.

In Argo workflows, we supported strftime to convert timestamps to other formats: https://github.com/argoproj/argo/blob/master/docs/workflow-controller-configmap.yaml#L62

We could introduce something similar to rollouts/analysis, e.g. {{analysis.startedAt.s}} would provide the analysis start time in unix epoch, since .s is the strftime representation of unix epoch.

@johnkost
Copy link

We have this same problem. Not sure how to tackle it yet as we need to provide start/end time for our metrics query

@johnkost
Copy link

@jessesuen - I'm looking at tackling this but curious the scope of it. The first stab could be adding {{rollout.deployedAt}} and {{analysis.startedAt}} (this allows me to compare all metrics between rollout and when the analysis was started which shouldn't be until after the pod is healthy).

Can I move time conversion to another issue?

@jessesuen jessesuen added analysis Related to Analysis CRD enhancement New feature or request labels Aug 4, 2020
@github-actions
Copy link
Contributor

github-actions bot commented Dec 7, 2022

This issue is stale because it has been open 60 days with no activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analysis Related to Analysis CRD enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants