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 start param to MTTR endpoints #20

Merged
merged 1 commit into from
Feb 8, 2024

Conversation

KevinMGranger
Copy link
Contributor

Addresses some items in #19

Copy link
Collaborator

@etsauer etsauer left a comment

Choose a reason for hiding this comment

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

Left some initial comments re: timestamps

// TODO: `@` in right spot?
static final String LEAD_TIME_FOR_CHANGE = "avg_over_time(sdp:lead_time:global [%s] @ %s)";
static final String BY_APP = "avg_over_time(sdp:lead_time:by_app{app=~'.*%s.*'}[%s] @ %s)";
static final String BY_APP_OFFSET = "avg_over_time(sdp:lead_time:by_app{app=~'.*%1$s.*'}[%2$s] offset %2$s)";
Copy link
Collaborator

Choose a reason for hiding this comment

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

@ is missing here

static final String BY_APP_OFFSET = "avg_over_time(sdp:lead_time:by_app{app=~'.*%1$s.*'}[%2$s] offset %2$s)";
// It should be this, once https://github.com/dora-metrics/pelorus/issues/1088
// gets resolved
static final String BY_APP_DATA = "sdp:lead_time:by_commit{app=~'.*%s.*'}[%s]";
Copy link
Collaborator

Choose a reason for hiding this comment

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

@ also missing here

}

// #region Change Failure Rate
// TODO: making sure I understand where the @ would go on the below queries
private final String CHANGE_FAILURE_RATE = "(count by (app) (count_over_time(failure_creation_timestamp{app!=\"unknown\"}[%1$s]) or sdp:lead_time:by_app * 0) / count_over_time(sdp:lead_time:by_app [%1$s]))";
Copy link
Collaborator

Choose a reason for hiding this comment

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

missing in all of CFR

@KevinMGranger KevinMGranger marked this pull request as ready for review February 8, 2024 18:06
- log queries
- take mandatory "start" parameter
- use a more structured argument approach
@KevinMGranger KevinMGranger changed the title WIP: Add start param to MTTR endpoints Add start param to MTTR endpoints Feb 8, 2024
Copy link
Collaborator

@etsauer etsauer left a comment

Choose a reason for hiding this comment

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

lgtm

@etsauer etsauer merged commit 750787f into dora-metrics:main Feb 8, 2024
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 this pull request may close these issues.

2 participants