Skip to content

fix(coderd): rewrite template insights query for speed and fix intervals #9300

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

Merged
merged 2 commits into from
Aug 24, 2023

Conversation

mafredri
Copy link
Member

This query is a bit more performant than the generate_series variant, with the reduction of intervals from 5 minute (generate_series) to 1 minute (date_trunc), we maintain ~ the same speed, albeit slightly faster, as #9299.

@mafredri mafredri requested review from mtojek and johnstcn August 24, 2023 11:05
@johnstcn
Copy link
Member

@mafredri Can you share some example query plans from before and after?

@mafredri mafredri merged commit 04d5e3f into main Aug 24, 2023
@mafredri mafredri deleted the mafredri/perf-improve-tempalte-insights-2 branch August 24, 2023 11:38
@github-actions github-actions bot locked and limited conversation to collaborators Aug 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants