feat(DM01-6252): add API performance Grafana dashboard and build.created_at index - #640
Open
liuwei08 wants to merge 2 commits into
Open
feat(DM01-6252): add API performance Grafana dashboard and build.created_at index#640liuwei08 wants to merge 2 commits into
liuwei08 wants to merge 2 commits into
Conversation
…ted_at index
- Add api_performance_dashboard.json with two rows:
- Project Activity: CPU allocation by project (Prometheus), most active
projects table and build submission rate (Postgres) — works immediately
with existing data sources
- API Request Metrics: endpoint request rate, top endpoints table and
latency p95 panels (Prometheus) — ready for when Flask middleware is
added, show "No data" until then
- Set dashboard auto-refresh to 5m to avoid excess DB load
- Add migration 00049 to create build_created_at_idx, eliminating full
table scans on time-range queries against the build table
…hboard queries and migration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
api_performance_dashboard.json— new Grafana dashboard with two rows:00049to createbuild_created_at_idxonbuild(created_at), eliminating full sequential scans on time-range queriesContext
Part of DM01-6252 / DM01-6243 — InfraBox performance investigation.
The existing Prometheus metrics server only exposes job counts and resource allocation. This dashboard adds visibility into which projects drive the most load, using existing data sources immediately, with placeholder panels ready for the upcoming Flask request metrics middleware.
Risk
00049usesIF NOT EXISTS; safe to re-run. Migration runner kills all connections before applying migrations so noCONCURRENTLYis needed