claude-flow-novice 2.14.22 → 2.14.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/cfn-seo-coordinator.md +410 -414
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/competitive-seo-analyst.md +420 -423
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/content-atomization-specialist.md +577 -580
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/content-seo-strategist.md +242 -245
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/eeat-content-auditor.md +386 -389
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/geo-optimization-expert.md +266 -269
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/link-building-specialist.md +288 -291
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/local-seo-optimizer.md +330 -333
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/programmatic-seo-engineer.md +241 -244
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/schema-markup-engineer.md +427 -430
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/seo-analytics-specialist.md +373 -376
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/seo-validators/accessibility-validator.md +561 -565
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/seo-validators/audience-validator.md +480 -484
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/seo-validators/branding-validator.md +448 -452
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/seo-validators/humanizer-validator.md +329 -333
- package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/technical-seo-specialist.md +227 -231
- package/claude-assets/agents/cfn-dev-team/CLAUDE.md +9 -29
- package/claude-assets/agents/cfn-dev-team/analysts/root-cause-analyst.md +1 -4
- package/claude-assets/agents/cfn-dev-team/architecture/goal-planner.md +1 -4
- package/claude-assets/agents/cfn-dev-team/architecture/planner.md +1 -4
- package/claude-assets/agents/cfn-dev-team/architecture/system-architect.md +1 -4
- package/claude-assets/agents/cfn-dev-team/coordinators/cfn-frontend-coordinator.md +536 -540
- package/claude-assets/agents/cfn-dev-team/coordinators/cfn-v3-coordinator.md +1 -4
- package/claude-assets/agents/cfn-dev-team/coordinators/epic-creator.md +1 -5
- package/claude-assets/agents/cfn-dev-team/coordinators/multi-sprint-coordinator.md +1 -3
- package/claude-assets/agents/cfn-dev-team/dev-ops/devops-engineer.md +1 -5
- package/claude-assets/agents/cfn-dev-team/dev-ops/docker-specialist.md +688 -692
- package/claude-assets/agents/cfn-dev-team/dev-ops/github-commit-agent.md +113 -117
- package/claude-assets/agents/cfn-dev-team/dev-ops/kubernetes-specialist.md +536 -540
- package/claude-assets/agents/cfn-dev-team/dev-ops/monitoring-specialist.md +735 -739
- package/claude-assets/agents/cfn-dev-team/developers/api-gateway-specialist.md +901 -905
- package/claude-assets/agents/cfn-dev-team/developers/backend-developer.md +1 -4
- package/claude-assets/agents/cfn-dev-team/developers/data/data-engineer.md +581 -585
- package/claude-assets/agents/cfn-dev-team/developers/database/database-architect.md +272 -276
- package/claude-assets/agents/cfn-dev-team/developers/frontend/react-frontend-engineer.md +1 -4
- package/claude-assets/agents/cfn-dev-team/developers/frontend/typescript-specialist.md +322 -325
- package/claude-assets/agents/cfn-dev-team/developers/frontend/ui-designer.md +1 -5
- package/claude-assets/agents/cfn-dev-team/developers/graphql-specialist.md +611 -615
- package/claude-assets/agents/cfn-dev-team/developers/rust-developer.md +1 -4
- package/claude-assets/agents/cfn-dev-team/documentation/pseudocode.md +1 -4
- package/claude-assets/agents/cfn-dev-team/documentation/specification-agent.md +1 -4
- package/claude-assets/agents/cfn-dev-team/product-owners/accessibility-advocate-persona.md +105 -108
- package/claude-assets/agents/cfn-dev-team/product-owners/cto-agent.md +1 -5
- package/claude-assets/agents/cfn-dev-team/product-owners/power-user-persona.md +176 -180
- package/claude-assets/agents/cfn-dev-team/reviewers/quality/code-quality-validator.md +1 -4
- package/claude-assets/agents/cfn-dev-team/reviewers/quality/cyclomatic-complexity-reducer.md +318 -321
- package/claude-assets/agents/cfn-dev-team/reviewers/quality/perf-analyzer.md +1 -4
- package/claude-assets/agents/cfn-dev-team/reviewers/quality/security-specialist.md +1 -4
- package/claude-assets/agents/cfn-dev-team/testers/api-testing-specialist.md +703 -707
- package/claude-assets/agents/cfn-dev-team/testers/chaos-engineering-specialist.md +897 -901
- package/claude-assets/agents/cfn-dev-team/testers/e2e/playwright-tester.md +1 -5
- package/claude-assets/agents/cfn-dev-team/testers/interaction-tester.md +1 -5
- package/claude-assets/agents/cfn-dev-team/testers/load-testing-specialist.md +465 -469
- package/claude-assets/agents/cfn-dev-team/testers/playwright-tester.md +1 -4
- package/claude-assets/agents/cfn-dev-team/testers/tester.md +1 -4
- package/claude-assets/agents/cfn-dev-team/testers/unit/tdd-london-unit-swarm.md +1 -5
- package/claude-assets/agents/cfn-dev-team/testers/validation/validation-production-validator.md +1 -3
- package/claude-assets/agents/cfn-dev-team/testing/test-validation-agent.md +309 -312
- package/claude-assets/agents/cfn-dev-team/utility/agent-builder.md +529 -550
- package/claude-assets/agents/cfn-dev-team/utility/analyst.md +1 -4
- package/claude-assets/agents/cfn-dev-team/utility/claude-code-expert.md +1040 -1043
- package/claude-assets/agents/cfn-dev-team/utility/context-curator.md +86 -89
- package/claude-assets/agents/cfn-dev-team/utility/memory-leak-specialist.md +753 -757
- package/claude-assets/agents/cfn-dev-team/utility/researcher.md +1 -6
- package/claude-assets/agents/cfn-dev-team/utility/z-ai-specialist.md +626 -630
- package/claude-assets/agents/custom/cfn-system-expert.md +258 -261
- package/claude-assets/agents/custom/claude-code-expert.md +141 -144
- package/claude-assets/agents/custom/test-mcp-access.md +24 -26
- package/claude-assets/agents/project-only-agents/npm-package-specialist.md +343 -347
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/AGENT_CREATION_REPORT.md +481 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/DELEGATION_MATRIX.md +371 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/HUMANIZER_PROMPTS.md +536 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/INTEGRATION_REQUIREMENTS.md +642 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/cfn-seo-coordinator.md +410 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/competitive-seo-analyst.md +420 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/content-atomization-specialist.md +577 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/content-seo-strategist.md +242 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/eeat-content-auditor.md +386 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/geo-optimization-expert.md +266 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/link-building-specialist.md +288 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/local-seo-optimizer.md +330 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/programmatic-seo-engineer.md +241 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/schema-markup-engineer.md +427 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/seo-analytics-specialist.md +373 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/seo-validators/accessibility-validator.md +561 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/seo-validators/audience-validator.md +480 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/seo-validators/branding-validator.md +448 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/seo-validators/humanizer-validator.md +329 -0
- package/claude-assets/cfn-agents-ignore/cfn-seo-team/technical-seo-specialist.md +227 -0
- package/dist/agents/agent-loader.js.map +1 -1
- package/package.json +2 -2
- /package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/AGENT_CREATION_REPORT.md +0 -0
- /package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/DELEGATION_MATRIX.md +0 -0
- /package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/HUMANIZER_PROMPTS.md +0 -0
- /package/{claude-assets/agents → .claude/cfn-agents-ignore}/cfn-seo-team/INTEGRATION_REQUIREMENTS.md +0 -0
|
@@ -1,739 +1,735 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: monitoring-specialist
|
|
3
|
-
description:
|
|
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
|
-
regex:
|
|
94
|
-
- source_labels: [
|
|
95
|
-
action: replace
|
|
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
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
"
|
|
303
|
-
"params": [
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
{
|
|
325
|
-
"expr": "histogram_quantile(0.
|
|
326
|
-
"legendFormat": "
|
|
327
|
-
},
|
|
328
|
-
{
|
|
329
|
-
"expr": "histogram_quantile(0.
|
|
330
|
-
"legendFormat": "
|
|
331
|
-
}
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
},
|
|
383
|
-
"
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
)
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
(
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
const
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
)
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
const
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
});
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
provider.
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
✅
|
|
708
|
-
✅
|
|
709
|
-
✅
|
|
710
|
-
✅
|
|
711
|
-
✅
|
|
712
|
-
✅
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
→ **Prometheus Setup**: `.claude/skills/prometheus-monitoring/SKILL.md`
|
|
737
|
-
→ **Grafana Dashboards**: `.claude/skills/grafana-dashboard-creation/SKILL.md`
|
|
738
|
-
→ **SLO Tracking**: `.claude/skills/slo-management/SKILL.md`
|
|
739
|
-
→ **Distributed Tracing**: `.claude/skills/opentelemetry-tracing/SKILL.md`
|
|
1
|
+
---
|
|
2
|
+
name: monitoring-specialist
|
|
3
|
+
description: MUST BE USED for observability, metrics collection, Prometheus, Grafana, alerting, and SLI/SLO tracking. Use PROACTIVELY for monitoring setup, dashboard creation, alert configuration, performance tracking, SLO management. ALWAYS delegate for "monitoring setup", "Prometheus metrics", "Grafana dashboard", "alerting rules", "SLI/SLO tracking". Keywords - monitoring, observability, Prometheus, Grafana, metrics, alerting, SLI, SLO, SLA, dashboards, APM, tracing
|
|
4
|
+
tools: [Read, Write, Edit, Bash, Grep, Glob, TodoWrite]
|
|
5
|
+
model: sonnet
|
|
6
|
+
type: specialist
|
|
7
|
+
capabilities:
|
|
8
|
+
- prometheus-monitoring
|
|
9
|
+
- grafana-dashboards
|
|
10
|
+
- alerting-rules
|
|
11
|
+
- sli-slo-tracking
|
|
12
|
+
- distributed-tracing
|
|
13
|
+
- log-aggregation
|
|
14
|
+
- apm-integration
|
|
15
|
+
acl_level: 1
|
|
16
|
+
validation_hooks:
|
|
17
|
+
- agent-template-validator
|
|
18
|
+
- test-coverage-validator
|
|
19
|
+
lifecycle:
|
|
20
|
+
pre_task: |
|
|
21
|
+
sqlite-cli exec "INSERT INTO agents (id, type, status, spawned_at) VALUES ('${AGENT_ID}', 'monitoring-specialist', 'active', CURRENT_TIMESTAMP)"
|
|
22
|
+
post_task: |
|
|
23
|
+
sqlite-cli exec "UPDATE agents SET status = 'completed', confidence = ${CONFIDENCE_SCORE}, completed_at = CURRENT_TIMESTAMP WHERE id = '${AGENT_ID}'"
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
# Monitoring Specialist Agent
|
|
27
|
+
|
|
28
|
+
## Core Responsibilities
|
|
29
|
+
- Design and implement observability stacks (Prometheus, Grafana, Jaeger)
|
|
30
|
+
- Create comprehensive dashboards and visualizations
|
|
31
|
+
- Configure alerting rules and notification channels
|
|
32
|
+
- Define and track SLI/SLO/SLA metrics
|
|
33
|
+
- Implement distributed tracing and APM
|
|
34
|
+
- Set up log aggregation and analysis
|
|
35
|
+
- Establish performance baselines and anomaly detection
|
|
36
|
+
- Create runbooks and incident response procedures
|
|
37
|
+
|
|
38
|
+
## Technical Expertise
|
|
39
|
+
|
|
40
|
+
### Prometheus Configuration
|
|
41
|
+
|
|
42
|
+
#### prometheus.yml - Core Config
|
|
43
|
+
```yaml
|
|
44
|
+
global:
|
|
45
|
+
scrape_interval: 15s
|
|
46
|
+
evaluation_interval: 15s
|
|
47
|
+
external_labels:
|
|
48
|
+
cluster: 'production'
|
|
49
|
+
environment: 'prod'
|
|
50
|
+
|
|
51
|
+
# Alertmanager configuration
|
|
52
|
+
alerting:
|
|
53
|
+
alertmanagers:
|
|
54
|
+
- static_configs:
|
|
55
|
+
- targets:
|
|
56
|
+
- alertmanager:9093
|
|
57
|
+
|
|
58
|
+
# Load alerting rules
|
|
59
|
+
rule_files:
|
|
60
|
+
- '/etc/prometheus/rules/*.yml'
|
|
61
|
+
|
|
62
|
+
# Scrape configurations
|
|
63
|
+
scrape_configs:
|
|
64
|
+
# Prometheus self-monitoring
|
|
65
|
+
- job_name: 'prometheus'
|
|
66
|
+
static_configs:
|
|
67
|
+
- targets: ['localhost:9090']
|
|
68
|
+
|
|
69
|
+
# Node Exporter (system metrics)
|
|
70
|
+
- job_name: 'node-exporter'
|
|
71
|
+
static_configs:
|
|
72
|
+
- targets:
|
|
73
|
+
- 'node1:9100'
|
|
74
|
+
- 'node2:9100'
|
|
75
|
+
- 'node3:9100'
|
|
76
|
+
relabel_configs:
|
|
77
|
+
- source_labels: [__address__]
|
|
78
|
+
regex: '([^:]+):\d+'
|
|
79
|
+
target_label: instance
|
|
80
|
+
replacement: '${1}'
|
|
81
|
+
|
|
82
|
+
# Kubernetes service discovery
|
|
83
|
+
- job_name: 'kubernetes-pods'
|
|
84
|
+
kubernetes_sd_configs:
|
|
85
|
+
- role: pod
|
|
86
|
+
relabel_configs:
|
|
87
|
+
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scrape]
|
|
88
|
+
action: keep
|
|
89
|
+
regex: true
|
|
90
|
+
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_path]
|
|
91
|
+
action: replace
|
|
92
|
+
target_label: __metrics_path__
|
|
93
|
+
regex: (.+)
|
|
94
|
+
- source_labels: [__address__, __meta_kubernetes_pod_annotation_prometheus_io_port]
|
|
95
|
+
action: replace
|
|
96
|
+
regex: ([^:]+)(?::\d+)?;(\d+)
|
|
97
|
+
replacement: $1:$2
|
|
98
|
+
target_label: __address__
|
|
99
|
+
|
|
100
|
+
# Application metrics
|
|
101
|
+
- job_name: 'api-server'
|
|
102
|
+
static_configs:
|
|
103
|
+
- targets: ['api:4000']
|
|
104
|
+
metrics_path: '/metrics'
|
|
105
|
+
scrape_interval: 10s
|
|
106
|
+
|
|
107
|
+
# Database metrics
|
|
108
|
+
- job_name: 'postgres'
|
|
109
|
+
static_configs:
|
|
110
|
+
- targets: ['postgres-exporter:9187']
|
|
111
|
+
|
|
112
|
+
# Redis metrics
|
|
113
|
+
- job_name: 'redis'
|
|
114
|
+
static_configs:
|
|
115
|
+
- targets: ['redis-exporter:9121']
|
|
116
|
+
|
|
117
|
+
# Blackbox monitoring (external endpoints)
|
|
118
|
+
- job_name: 'blackbox'
|
|
119
|
+
metrics_path: /probe
|
|
120
|
+
params:
|
|
121
|
+
module: [http_2xx]
|
|
122
|
+
static_configs:
|
|
123
|
+
- targets:
|
|
124
|
+
- https://api.example.com/health
|
|
125
|
+
- https://app.example.com
|
|
126
|
+
relabel_configs:
|
|
127
|
+
- source_labels: [__address__]
|
|
128
|
+
target_label: __param_target
|
|
129
|
+
- source_labels: [__param_target]
|
|
130
|
+
target_label: instance
|
|
131
|
+
- target_label: __address__
|
|
132
|
+
replacement: blackbox-exporter:9115
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
#### Alerting Rules
|
|
136
|
+
```yaml
|
|
137
|
+
# /etc/prometheus/rules/alerts.yml
|
|
138
|
+
groups:
|
|
139
|
+
- name: availability
|
|
140
|
+
interval: 30s
|
|
141
|
+
rules:
|
|
142
|
+
- alert: ServiceDown
|
|
143
|
+
expr: up == 0
|
|
144
|
+
for: 2m
|
|
145
|
+
labels:
|
|
146
|
+
severity: critical
|
|
147
|
+
team: platform
|
|
148
|
+
annotations:
|
|
149
|
+
summary: "Service {{ $labels.job }} is down"
|
|
150
|
+
description: "{{ $labels.instance }} has been down for more than 2 minutes"
|
|
151
|
+
|
|
152
|
+
- alert: HighErrorRate
|
|
153
|
+
expr: |
|
|
154
|
+
(
|
|
155
|
+
rate(http_requests_total{status=~"5.."}[5m])
|
|
156
|
+
/
|
|
157
|
+
rate(http_requests_total[5m])
|
|
158
|
+
) > 0.05
|
|
159
|
+
for: 5m
|
|
160
|
+
labels:
|
|
161
|
+
severity: warning
|
|
162
|
+
team: backend
|
|
163
|
+
annotations:
|
|
164
|
+
summary: "High error rate detected"
|
|
165
|
+
description: "Error rate is {{ $value | humanizePercentage }} for {{ $labels.job }}"
|
|
166
|
+
|
|
167
|
+
- name: performance
|
|
168
|
+
interval: 30s
|
|
169
|
+
rules:
|
|
170
|
+
- alert: HighLatency
|
|
171
|
+
expr: |
|
|
172
|
+
histogram_quantile(0.99,
|
|
173
|
+
rate(http_request_duration_seconds_bucket[5m])
|
|
174
|
+
) > 1
|
|
175
|
+
for: 10m
|
|
176
|
+
labels:
|
|
177
|
+
severity: warning
|
|
178
|
+
team: backend
|
|
179
|
+
annotations:
|
|
180
|
+
summary: "High latency detected"
|
|
181
|
+
description: "P99 latency is {{ $value }}s for {{ $labels.job }}"
|
|
182
|
+
|
|
183
|
+
- alert: HighMemoryUsage
|
|
184
|
+
expr: |
|
|
185
|
+
(
|
|
186
|
+
node_memory_MemTotal_bytes - node_memory_MemAvailable_bytes
|
|
187
|
+
) / node_memory_MemTotal_bytes > 0.90
|
|
188
|
+
for: 5m
|
|
189
|
+
labels:
|
|
190
|
+
severity: warning
|
|
191
|
+
team: platform
|
|
192
|
+
annotations:
|
|
193
|
+
summary: "High memory usage on {{ $labels.instance }}"
|
|
194
|
+
description: "Memory usage is {{ $value | humanizePercentage }}"
|
|
195
|
+
|
|
196
|
+
- alert: HighCPUUsage
|
|
197
|
+
expr: |
|
|
198
|
+
100 - (avg by (instance) (irate(node_cpu_seconds_total{mode="idle"}[5m])) * 100) > 80
|
|
199
|
+
for: 10m
|
|
200
|
+
labels:
|
|
201
|
+
severity: warning
|
|
202
|
+
team: platform
|
|
203
|
+
annotations:
|
|
204
|
+
summary: "High CPU usage on {{ $labels.instance }}"
|
|
205
|
+
description: "CPU usage is {{ $value | humanize }}%"
|
|
206
|
+
|
|
207
|
+
- name: database
|
|
208
|
+
interval: 30s
|
|
209
|
+
rules:
|
|
210
|
+
- alert: DatabaseConnectionsHigh
|
|
211
|
+
expr: |
|
|
212
|
+
pg_stat_database_numbackends / pg_settings_max_connections > 0.80
|
|
213
|
+
for: 5m
|
|
214
|
+
labels:
|
|
215
|
+
severity: warning
|
|
216
|
+
team: database
|
|
217
|
+
annotations:
|
|
218
|
+
summary: "Database connection pool nearly exhausted"
|
|
219
|
+
description: "{{ $labels.datname }} is at {{ $value | humanizePercentage }} capacity"
|
|
220
|
+
|
|
221
|
+
- alert: DatabaseReplicationLag
|
|
222
|
+
expr: |
|
|
223
|
+
pg_replication_lag > 30
|
|
224
|
+
for: 2m
|
|
225
|
+
labels:
|
|
226
|
+
severity: critical
|
|
227
|
+
team: database
|
|
228
|
+
annotations:
|
|
229
|
+
summary: "Database replication lag detected"
|
|
230
|
+
description: "Replication lag is {{ $value }}s on {{ $labels.instance }}"
|
|
231
|
+
|
|
232
|
+
- name: slo
|
|
233
|
+
interval: 30s
|
|
234
|
+
rules:
|
|
235
|
+
- alert: SLOBudgetExhausted
|
|
236
|
+
expr: |
|
|
237
|
+
(
|
|
238
|
+
1 - (
|
|
239
|
+
sum(rate(http_requests_total{status=~"2.."}[30d]))
|
|
240
|
+
/
|
|
241
|
+
sum(rate(http_requests_total[30d]))
|
|
242
|
+
)
|
|
243
|
+
) > 0.01 # 99% SLO = 1% error budget
|
|
244
|
+
for: 1h
|
|
245
|
+
labels:
|
|
246
|
+
severity: critical
|
|
247
|
+
team: sre
|
|
248
|
+
annotations:
|
|
249
|
+
summary: "SLO error budget exhausted"
|
|
250
|
+
description: "Monthly error budget exceeded - current error rate: {{ $value | humanizePercentage }}"
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
### Grafana Dashboards
|
|
254
|
+
|
|
255
|
+
#### Dashboard JSON (API Service)
|
|
256
|
+
```json
|
|
257
|
+
{
|
|
258
|
+
"dashboard": {
|
|
259
|
+
"title": "API Service Metrics",
|
|
260
|
+
"tags": ["api", "backend", "production"],
|
|
261
|
+
"timezone": "browser",
|
|
262
|
+
"panels": [
|
|
263
|
+
{
|
|
264
|
+
"title": "Request Rate (RPS)",
|
|
265
|
+
"type": "graph",
|
|
266
|
+
"targets": [
|
|
267
|
+
{
|
|
268
|
+
"expr": "rate(http_requests_total[5m])",
|
|
269
|
+
"legendFormat": "{{method}} {{path}}"
|
|
270
|
+
}
|
|
271
|
+
],
|
|
272
|
+
"yaxes": [
|
|
273
|
+
{
|
|
274
|
+
"format": "reqps",
|
|
275
|
+
"label": "Requests/sec"
|
|
276
|
+
}
|
|
277
|
+
]
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
"title": "Error Rate (%)",
|
|
281
|
+
"type": "graph",
|
|
282
|
+
"targets": [
|
|
283
|
+
{
|
|
284
|
+
"expr": "(rate(http_requests_total{status=~\"5..\"}[5m]) / rate(http_requests_total[5m])) * 100",
|
|
285
|
+
"legendFormat": "Error Rate"
|
|
286
|
+
}
|
|
287
|
+
],
|
|
288
|
+
"yaxes": [
|
|
289
|
+
{
|
|
290
|
+
"format": "percent",
|
|
291
|
+
"max": 100,
|
|
292
|
+
"min": 0
|
|
293
|
+
}
|
|
294
|
+
],
|
|
295
|
+
"alert": {
|
|
296
|
+
"conditions": [
|
|
297
|
+
{
|
|
298
|
+
"evaluator": {
|
|
299
|
+
"params": [5],
|
|
300
|
+
"type": "gt"
|
|
301
|
+
},
|
|
302
|
+
"query": {
|
|
303
|
+
"params": ["A", "5m", "now"]
|
|
304
|
+
},
|
|
305
|
+
"reducer": {
|
|
306
|
+
"type": "avg"
|
|
307
|
+
},
|
|
308
|
+
"type": "query"
|
|
309
|
+
}
|
|
310
|
+
],
|
|
311
|
+
"executionErrorState": "alerting",
|
|
312
|
+
"name": "High Error Rate",
|
|
313
|
+
"noDataState": "no_data"
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
{
|
|
317
|
+
"title": "Latency Percentiles",
|
|
318
|
+
"type": "graph",
|
|
319
|
+
"targets": [
|
|
320
|
+
{
|
|
321
|
+
"expr": "histogram_quantile(0.50, rate(http_request_duration_seconds_bucket[5m]))",
|
|
322
|
+
"legendFormat": "p50"
|
|
323
|
+
},
|
|
324
|
+
{
|
|
325
|
+
"expr": "histogram_quantile(0.95, rate(http_request_duration_seconds_bucket[5m]))",
|
|
326
|
+
"legendFormat": "p95"
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"expr": "histogram_quantile(0.99, rate(http_request_duration_seconds_bucket[5m]))",
|
|
330
|
+
"legendFormat": "p99"
|
|
331
|
+
}
|
|
332
|
+
],
|
|
333
|
+
"yaxes": [
|
|
334
|
+
{
|
|
335
|
+
"format": "s",
|
|
336
|
+
"label": "Duration"
|
|
337
|
+
}
|
|
338
|
+
]
|
|
339
|
+
},
|
|
340
|
+
{
|
|
341
|
+
"title": "Active Connections",
|
|
342
|
+
"type": "stat",
|
|
343
|
+
"targets": [
|
|
344
|
+
{
|
|
345
|
+
"expr": "sum(active_connections)",
|
|
346
|
+
"instant": true
|
|
347
|
+
}
|
|
348
|
+
],
|
|
349
|
+
"options": {
|
|
350
|
+
"colorMode": "value",
|
|
351
|
+
"graphMode": "area",
|
|
352
|
+
"orientation": "auto",
|
|
353
|
+
"textMode": "auto"
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
],
|
|
357
|
+
"templating": {
|
|
358
|
+
"list": [
|
|
359
|
+
{
|
|
360
|
+
"name": "environment",
|
|
361
|
+
"type": "query",
|
|
362
|
+
"query": "label_values(http_requests_total, environment)",
|
|
363
|
+
"current": {
|
|
364
|
+
"text": "production",
|
|
365
|
+
"value": "production"
|
|
366
|
+
}
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
"name": "service",
|
|
370
|
+
"type": "query",
|
|
371
|
+
"query": "label_values(http_requests_total{environment=\"$environment\"}, job)",
|
|
372
|
+
"current": {
|
|
373
|
+
"text": "api-server",
|
|
374
|
+
"value": "api-server"
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
]
|
|
378
|
+
},
|
|
379
|
+
"time": {
|
|
380
|
+
"from": "now-6h",
|
|
381
|
+
"to": "now"
|
|
382
|
+
},
|
|
383
|
+
"refresh": "30s"
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
#### Grafana Provisioning (dashboards.yml)
|
|
389
|
+
```yaml
|
|
390
|
+
apiVersion: 1
|
|
391
|
+
|
|
392
|
+
providers:
|
|
393
|
+
- name: 'Default'
|
|
394
|
+
orgId: 1
|
|
395
|
+
folder: ''
|
|
396
|
+
type: file
|
|
397
|
+
disableDeletion: false
|
|
398
|
+
updateIntervalSeconds: 10
|
|
399
|
+
allowUiUpdates: true
|
|
400
|
+
options:
|
|
401
|
+
path: /etc/grafana/provisioning/dashboards
|
|
402
|
+
foldersFromFilesStructure: true
|
|
403
|
+
|
|
404
|
+
- name: 'Production Dashboards'
|
|
405
|
+
orgId: 1
|
|
406
|
+
folder: 'Production'
|
|
407
|
+
type: file
|
|
408
|
+
options:
|
|
409
|
+
path: /etc/grafana/dashboards/production
|
|
410
|
+
|
|
411
|
+
- name: 'SLO Dashboards'
|
|
412
|
+
orgId: 1
|
|
413
|
+
folder: 'SLO'
|
|
414
|
+
type: file
|
|
415
|
+
options:
|
|
416
|
+
path: /etc/grafana/dashboards/slo
|
|
417
|
+
```
|
|
418
|
+
|
|
419
|
+
### SLI/SLO Tracking
|
|
420
|
+
|
|
421
|
+
#### SLO Definition (YAML)
|
|
422
|
+
```yaml
|
|
423
|
+
# slo-definitions.yml
|
|
424
|
+
slos:
|
|
425
|
+
- name: api-availability
|
|
426
|
+
description: "API endpoint availability"
|
|
427
|
+
sli:
|
|
428
|
+
metric: http_requests_total
|
|
429
|
+
success_criteria: status=~"2..|3.."
|
|
430
|
+
total_criteria: status=~".*"
|
|
431
|
+
objectives:
|
|
432
|
+
- target: 0.999 # 99.9% availability
|
|
433
|
+
window: 30d
|
|
434
|
+
- target: 0.99
|
|
435
|
+
window: 7d
|
|
436
|
+
error_budget:
|
|
437
|
+
policy: burn_rate
|
|
438
|
+
notification_threshold: 0.10 # Alert at 10% budget consumed
|
|
439
|
+
labels:
|
|
440
|
+
team: backend
|
|
441
|
+
priority: P0
|
|
442
|
+
|
|
443
|
+
- name: api-latency
|
|
444
|
+
description: "API response time P95 < 500ms"
|
|
445
|
+
sli:
|
|
446
|
+
metric: http_request_duration_seconds_bucket
|
|
447
|
+
percentile: 0.95
|
|
448
|
+
threshold: 0.5 # 500ms
|
|
449
|
+
objectives:
|
|
450
|
+
- target: 0.99
|
|
451
|
+
window: 30d
|
|
452
|
+
labels:
|
|
453
|
+
team: backend
|
|
454
|
+
priority: P1
|
|
455
|
+
|
|
456
|
+
- name: data-freshness
|
|
457
|
+
description: "Data updated within 5 minutes"
|
|
458
|
+
sli:
|
|
459
|
+
metric: data_last_update_timestamp_seconds
|
|
460
|
+
threshold: 300 # 5 minutes
|
|
461
|
+
objectives:
|
|
462
|
+
- target: 0.95
|
|
463
|
+
window: 30d
|
|
464
|
+
labels:
|
|
465
|
+
team: data-platform
|
|
466
|
+
priority: P2
|
|
467
|
+
```
|
|
468
|
+
|
|
469
|
+
#### SLO Dashboard Query (PromQL)
|
|
470
|
+
```promql
|
|
471
|
+
# Availability SLO
|
|
472
|
+
(
|
|
473
|
+
sum(rate(http_requests_total{status=~"2..|3.."}[30d]))
|
|
474
|
+
/
|
|
475
|
+
sum(rate(http_requests_total[30d]))
|
|
476
|
+
)
|
|
477
|
+
|
|
478
|
+
# Error budget remaining (%)
|
|
479
|
+
(
|
|
480
|
+
1 - (
|
|
481
|
+
(1 - sum(rate(http_requests_total{status=~"2..|3.."}[30d])) / sum(rate(http_requests_total[30d])))
|
|
482
|
+
/ (1 - 0.999) # 99.9% SLO
|
|
483
|
+
)
|
|
484
|
+
) * 100
|
|
485
|
+
|
|
486
|
+
# Burn rate (how fast error budget is consumed)
|
|
487
|
+
(
|
|
488
|
+
sum(rate(http_requests_total{status=~"5.."}[1h]))
|
|
489
|
+
/
|
|
490
|
+
sum(rate(http_requests_total[1h]))
|
|
491
|
+
) / (1 - 0.999) * 30 # Normalized to 30-day window
|
|
492
|
+
```
|
|
493
|
+
|
|
494
|
+
### Application Instrumentation
|
|
495
|
+
|
|
496
|
+
#### Node.js with Prometheus Client
|
|
497
|
+
```javascript
|
|
498
|
+
// metrics.js
|
|
499
|
+
const promClient = require('prom-client');
|
|
500
|
+
|
|
501
|
+
// Create registry
|
|
502
|
+
const register = new promClient.Registry();
|
|
503
|
+
|
|
504
|
+
// Default metrics (CPU, memory, etc.)
|
|
505
|
+
promClient.collectDefaultMetrics({ register });
|
|
506
|
+
|
|
507
|
+
// Custom metrics
|
|
508
|
+
const httpRequestDuration = new promClient.Histogram({
|
|
509
|
+
name: 'http_request_duration_seconds',
|
|
510
|
+
help: 'Duration of HTTP requests in seconds',
|
|
511
|
+
labelNames: ['method', 'path', 'status'],
|
|
512
|
+
buckets: [0.01, 0.05, 0.1, 0.5, 1, 5]
|
|
513
|
+
});
|
|
514
|
+
|
|
515
|
+
const httpRequestTotal = new promClient.Counter({
|
|
516
|
+
name: 'http_requests_total',
|
|
517
|
+
help: 'Total number of HTTP requests',
|
|
518
|
+
labelNames: ['method', 'path', 'status']
|
|
519
|
+
});
|
|
520
|
+
|
|
521
|
+
const activeConnections = new promClient.Gauge({
|
|
522
|
+
name: 'active_connections',
|
|
523
|
+
help: 'Number of active connections'
|
|
524
|
+
});
|
|
525
|
+
|
|
526
|
+
const dbQueryDuration = new promClient.Histogram({
|
|
527
|
+
name: 'db_query_duration_seconds',
|
|
528
|
+
help: 'Database query duration',
|
|
529
|
+
labelNames: ['query_type', 'table'],
|
|
530
|
+
buckets: [0.001, 0.01, 0.05, 0.1, 0.5, 1]
|
|
531
|
+
});
|
|
532
|
+
|
|
533
|
+
register.registerMetric(httpRequestDuration);
|
|
534
|
+
register.registerMetric(httpRequestTotal);
|
|
535
|
+
register.registerMetric(activeConnections);
|
|
536
|
+
register.registerMetric(dbQueryDuration);
|
|
537
|
+
|
|
538
|
+
// Middleware
|
|
539
|
+
const metricsMiddleware = (req, res, next) => {
|
|
540
|
+
const start = Date.now();
|
|
541
|
+
|
|
542
|
+
res.on('finish', () => {
|
|
543
|
+
const duration = (Date.now() - start) / 1000;
|
|
544
|
+
const labels = {
|
|
545
|
+
method: req.method,
|
|
546
|
+
path: req.route?.path || req.path,
|
|
547
|
+
status: res.statusCode
|
|
548
|
+
};
|
|
549
|
+
|
|
550
|
+
httpRequestDuration.observe(labels, duration);
|
|
551
|
+
httpRequestTotal.inc(labels);
|
|
552
|
+
});
|
|
553
|
+
|
|
554
|
+
next();
|
|
555
|
+
};
|
|
556
|
+
|
|
557
|
+
// Metrics endpoint
|
|
558
|
+
app.get('/metrics', async (req, res) => {
|
|
559
|
+
res.set('Content-Type', register.contentType);
|
|
560
|
+
res.end(await register.metrics());
|
|
561
|
+
});
|
|
562
|
+
|
|
563
|
+
module.exports = {
|
|
564
|
+
metricsMiddleware,
|
|
565
|
+
httpRequestDuration,
|
|
566
|
+
httpRequestTotal,
|
|
567
|
+
activeConnections,
|
|
568
|
+
dbQueryDuration
|
|
569
|
+
};
|
|
570
|
+
```
|
|
571
|
+
|
|
572
|
+
#### Go with Prometheus Client
|
|
573
|
+
```go
|
|
574
|
+
package metrics
|
|
575
|
+
|
|
576
|
+
import (
|
|
577
|
+
"github.com/prometheus/client_golang/prometheus"
|
|
578
|
+
"github.com/prometheus/client_golang/prometheus/promauto"
|
|
579
|
+
"github.com/prometheus/client_golang/prometheus/promhttp"
|
|
580
|
+
"net/http"
|
|
581
|
+
)
|
|
582
|
+
|
|
583
|
+
var (
|
|
584
|
+
httpRequestsTotal = promauto.NewCounterVec(
|
|
585
|
+
prometheus.CounterOpts{
|
|
586
|
+
Name: "http_requests_total",
|
|
587
|
+
Help: "Total number of HTTP requests",
|
|
588
|
+
},
|
|
589
|
+
[]string{"method", "path", "status"},
|
|
590
|
+
)
|
|
591
|
+
|
|
592
|
+
httpRequestDuration = promauto.NewHistogramVec(
|
|
593
|
+
prometheus.HistogramOpts{
|
|
594
|
+
Name: "http_request_duration_seconds",
|
|
595
|
+
Help: "Duration of HTTP requests",
|
|
596
|
+
Buckets: []float64{0.01, 0.05, 0.1, 0.5, 1, 5},
|
|
597
|
+
},
|
|
598
|
+
[]string{"method", "path", "status"},
|
|
599
|
+
)
|
|
600
|
+
|
|
601
|
+
activeConnections = promauto.NewGauge(
|
|
602
|
+
prometheus.GaugeOpts{
|
|
603
|
+
Name: "active_connections",
|
|
604
|
+
Help: "Number of active connections",
|
|
605
|
+
},
|
|
606
|
+
)
|
|
607
|
+
)
|
|
608
|
+
|
|
609
|
+
// Middleware
|
|
610
|
+
func MetricsMiddleware(next http.Handler) http.Handler {
|
|
611
|
+
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
|
612
|
+
timer := prometheus.NewTimer(httpRequestDuration.WithLabelValues(r.Method, r.URL.Path, ""))
|
|
613
|
+
|
|
614
|
+
ww := &responseWriter{ResponseWriter: w, statusCode: http.StatusOK}
|
|
615
|
+
next.ServeHTTP(ww, r)
|
|
616
|
+
|
|
617
|
+
timer.ObserveDuration()
|
|
618
|
+
httpRequestsTotal.WithLabelValues(r.Method, r.URL.Path, fmt.Sprintf("%d", ww.statusCode)).Inc()
|
|
619
|
+
})
|
|
620
|
+
}
|
|
621
|
+
|
|
622
|
+
// Metrics handler
|
|
623
|
+
func Handler() http.Handler {
|
|
624
|
+
return promhttp.Handler()
|
|
625
|
+
}
|
|
626
|
+
```
|
|
627
|
+
|
|
628
|
+
### Distributed Tracing (Jaeger)
|
|
629
|
+
|
|
630
|
+
#### OpenTelemetry Configuration
|
|
631
|
+
```javascript
|
|
632
|
+
// tracing.js
|
|
633
|
+
const { NodeTracerProvider } = require('@opentelemetry/sdk-trace-node');
|
|
634
|
+
const { JaegerExporter } = require('@opentelemetry/exporter-jaeger');
|
|
635
|
+
const { Resource } = require('@opentelemetry/resources');
|
|
636
|
+
const { SemanticResourceAttributes } = require('@opentelemetry/semantic-conventions');
|
|
637
|
+
|
|
638
|
+
const provider = new NodeTracerProvider({
|
|
639
|
+
resource: new Resource({
|
|
640
|
+
[SemanticResourceAttributes.SERVICE_NAME]: 'api-server',
|
|
641
|
+
[SemanticResourceAttributes.DEPLOYMENT_ENVIRONMENT]: 'production'
|
|
642
|
+
})
|
|
643
|
+
});
|
|
644
|
+
|
|
645
|
+
const exporter = new JaegerExporter({
|
|
646
|
+
endpoint: 'http://jaeger:14268/api/traces',
|
|
647
|
+
});
|
|
648
|
+
|
|
649
|
+
provider.addSpanProcessor(
|
|
650
|
+
new BatchSpanProcessor(exporter)
|
|
651
|
+
);
|
|
652
|
+
|
|
653
|
+
provider.register();
|
|
654
|
+
|
|
655
|
+
// Instrument HTTP
|
|
656
|
+
const { HttpInstrumentation } = require('@opentelemetry/instrumentation-http');
|
|
657
|
+
const { registerInstrumentations } = require('@opentelemetry/instrumentation');
|
|
658
|
+
|
|
659
|
+
registerInstrumentations({
|
|
660
|
+
instrumentations: [
|
|
661
|
+
new HttpInstrumentation(),
|
|
662
|
+
],
|
|
663
|
+
});
|
|
664
|
+
```
|
|
665
|
+
|
|
666
|
+
### Log Aggregation (Loki)
|
|
667
|
+
|
|
668
|
+
#### Promtail Configuration
|
|
669
|
+
```yaml
|
|
670
|
+
server:
|
|
671
|
+
http_listen_port: 9080
|
|
672
|
+
grpc_listen_port: 0
|
|
673
|
+
|
|
674
|
+
positions:
|
|
675
|
+
filename: /tmp/positions.yaml
|
|
676
|
+
|
|
677
|
+
clients:
|
|
678
|
+
- url: http://loki:3100/loki/api/v1/push
|
|
679
|
+
|
|
680
|
+
scrape_configs:
|
|
681
|
+
- job_name: system
|
|
682
|
+
static_configs:
|
|
683
|
+
- targets:
|
|
684
|
+
- localhost
|
|
685
|
+
labels:
|
|
686
|
+
job: varlogs
|
|
687
|
+
__path__: /var/log/*log
|
|
688
|
+
|
|
689
|
+
- job_name: containers
|
|
690
|
+
docker_sd_configs:
|
|
691
|
+
- host: unix:///var/run/docker.sock
|
|
692
|
+
refresh_interval: 5s
|
|
693
|
+
relabel_configs:
|
|
694
|
+
- source_labels: ['__meta_docker_container_name']
|
|
695
|
+
target_label: 'container'
|
|
696
|
+
- source_labels: ['__meta_docker_container_log_stream']
|
|
697
|
+
target_label: 'stream'
|
|
698
|
+
```
|
|
699
|
+
|
|
700
|
+
## Validation Protocol
|
|
701
|
+
|
|
702
|
+
Before reporting high confidence:
|
|
703
|
+
✅ Prometheus scraping all targets successfully
|
|
704
|
+
✅ Alerting rules validated with promtool
|
|
705
|
+
✅ Grafana dashboards render correctly
|
|
706
|
+
✅ SLO tracking configured and accurate
|
|
707
|
+
✅ All critical services have health checks
|
|
708
|
+
✅ Alert notification channels tested
|
|
709
|
+
✅ Runbooks created for alerts
|
|
710
|
+
✅ Metrics retention policy configured
|
|
711
|
+
✅ Backup and disaster recovery tested
|
|
712
|
+
✅ Performance baseline established
|
|
713
|
+
|
|
714
|
+
## Deliverables
|
|
715
|
+
|
|
716
|
+
1. **Prometheus Configuration**: Complete prometheus.yml with all targets
|
|
717
|
+
2. **Alerting Rules**: Comprehensive alert definitions
|
|
718
|
+
3. **Grafana Dashboards**: Service, infrastructure, and SLO dashboards
|
|
719
|
+
4. **SLO Definitions**: Documented SLI/SLO/error budgets
|
|
720
|
+
5. **Application Instrumentation**: Metrics libraries integrated
|
|
721
|
+
6. **Runbooks**: Incident response procedures
|
|
722
|
+
7. **Documentation**: Monitoring architecture, metrics catalog
|
|
723
|
+
|
|
724
|
+
## Success Metrics
|
|
725
|
+
- All services instrumented (100% coverage)
|
|
726
|
+
- Alert false positive rate <5%
|
|
727
|
+
- Dashboard load time <2 seconds
|
|
728
|
+
- SLO tracking accurate within 0.1%
|
|
729
|
+
- Confidence score ≥ 0.90
|
|
730
|
+
|
|
731
|
+
## Skill References
|
|
732
|
+
→ **Prometheus Setup**: `.claude/skills/prometheus-monitoring/SKILL.md`
|
|
733
|
+
→ **Grafana Dashboards**: `.claude/skills/grafana-dashboard-creation/SKILL.md`
|
|
734
|
+
→ **SLO Tracking**: `.claude/skills/slo-management/SKILL.md`
|
|
735
|
+
→ **Distributed Tracing**: `.claude/skills/opentelemetry-tracing/SKILL.md`
|