Repository navigation
Commit 6502e54
* feat(grafana_irm): add Grafana IRM incident collection plugin
* test(grafana_irm): add richer live-captured e2e/unit fixtures; implement TestConnection
- Seed 2 more real (non-drill) incidents on the dev stack with a real role
assignment and multi-label data, closing gaps the original 2-incident
fixture never exercised (assignment mapping, per-scope label exclusion).
- Add a second e2e scenario proving label-based scope filtering end-to-end.
- Update the extractor unit test to use real captured incident data instead
of a drill incident's.
- Implement TestConnection/TestExistingConnection via a cheap
IncidentsService.QueryIncidents call, verified live against the real API.
* refactor(grafana_irm): revert to connection-wide scoping, drop label filtering
The originating feature request only asks for org-wide DORA correlation and
never mentions per-team scoping. The label-based per-scope filtering added
earlier this session was real and tested, but solved a problem nobody asked
for, and config-ui has no generic manual-scope-entry component to build a UI
for it on top of. Revert GrafanaIrmScopeConfig/GrafanaIrmOptions/the
collector/converter to a single connection-wide scope with no filtering, same
shape as incidentio/pagerduty. All incident labels are still collected and
stored unconditionally, just no longer used to gate conversion.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
* feat(grafana_irm): add config-ui frontend and single-scope remote API
Backend: add remote_api.go returning the one synthetic scope every
connection has (config-ui's data-scope picker has no manual-entry flow to
fall back to, so this feeds the standard remote-picker UI a single 'All
Incidents' entry instead), wired into impl.go's routes. Frontend: add config-ui/src/plugins/register/grafana_irm (connection form,
icon, registration) mirroring incidentio's shape, using the Grafana logo
already vendored under grafana/img/. No custom scope-config UI is needed
since GrafanaIrmScopeConfig carries no extra fields (Option A). Verified
with tsc, eslint, and a production vite build - all clean.
* fix(grafana_irm): fix error raised during testing
* refactor(grafana_irm): collapse collect+refresh into one FinalizableApiCollector subtask
The two-subtask design (CollectIncidents + RefreshOpenIncidents) caused three
real bugs found via live pipeline testing: a panic, "Re-transform Data"
silently deleting resolved incidents, and a genuine full sync also losing
data because both subtasks independently wiped the raw table with no
coordination between them.
pagerduty solves the identical "list new/changed, then refresh still-open"
need with DevLake's own FinalizableApiCollector as a single subtask, which
prevents these bugs by construction (the framework never builds the
"refresh" half on a full sync, and there's only one subtask name for
Re-transform Data's filter to strip). Migrated CollectIncidents to that
pattern; all existing collector logic (query building, change-detection via
a request-scoped header) preserved, just re-wired. Live-verified against a
real server: full sync restores all incidents correctly, incremental sync
has no regression, and Re-transform Data no longer drops resolved incidents.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
* feat(grafana_irm): add dedicated Grafana dashboard, docs, and domain board mapping
- Add dedicated Grafana dashboards for MySQL and PostgreSQL dialects
- Populate domain ticket.Board in ConvertIncidents to enable board filtering and joins
- Update config-ui brand icon with official Grafana flame SVG
- Add plugin documentation in backend/plugins/grafana_irm/README.md
- Fix struct alignment formatting in models/incident.go
* fix(grafana_irm): improve connection test error messages and add docs link
* fix(grafana_irm): truncate timestamps to milliseconds and fix e2e postgres scope setup
---------
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
1 parent f3d8859 commit 6502e54
52 files changed
Lines changed: 7266 additions & 0 deletions
File tree
- backend
- plugins
- grafana_irm
- api
- e2e
- raw_tables
- snapshot_tables
- impl
- models
- migrationscripts
- archived
- raw
- tasks
- schema_e2e
- test/e2e/services
- config-ui/src/plugins/register
- grafana_irm
- assets
- grafana/dashboards
- mysql
- postgresql
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
0 commit comments