-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdodex-indexer-dashboard.json
More file actions
921 lines (921 loc) · 35.7 KB
/
Copy pathdodex-indexer-dashboard.json
File metadata and controls
921 lines (921 loc) · 35.7 KB
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
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
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
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
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
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
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
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
{
"annotations": {
"list": [
{
"builtIn": 1,
"datasource": { "type": "grafana", "uid": "-- Grafana --" },
"enable": true,
"hide": true,
"iconColor": "rgba(0, 211, 255, 1)",
"name": "Annotations & Alerts",
"type": "dashboard"
}
]
},
"description": "All OTLP metrics exported by the dodex indexer (service.name=dodex-indexer), via a Prometheus data source. Counters carry the OTel-default _total suffix; flip the 'counter_suffix' variable to empty if your collector sets add_metric_suffixes:false.",
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 1,
"links": [],
"liveNow": false,
"refresh": "30s",
"schemaVersion": 39,
"tags": ["dodex", "indexer", "inference"],
"templating": {
"list": [
{
"current": {},
"hide": 0,
"includeAll": false,
"label": "Data source",
"multi": false,
"name": "datasource",
"options": [],
"query": "prometheus",
"refresh": 1,
"regex": "",
"type": "datasource"
},
{
"current": { "text": "All", "value": "$__all" },
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"definition": "label_values(indexer_projection_backlog, job)",
"hide": 0,
"includeAll": true,
"allValue": ".*",
"label": "job",
"multi": true,
"name": "job",
"options": [],
"query": {
"query": "label_values(indexer_projection_backlog, job)",
"refId": "PrometheusVariableQueryEditor-VariableQuery"
},
"refresh": 2,
"regex": "",
"sort": 1,
"type": "query"
},
{
"current": { "text": "All", "value": "$__all" },
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"definition": "label_values(indexer_projection_backlog{job=~\"$job\"}, instance)",
"hide": 0,
"includeAll": true,
"allValue": ".*",
"label": "instance",
"multi": true,
"name": "instance",
"options": [],
"query": {
"query": "label_values(indexer_projection_backlog{job=~\"$job\"}, instance)",
"refId": "PrometheusVariableQueryEditor-VariableQuery"
},
"refresh": 2,
"regex": "",
"sort": 1,
"type": "query"
},
{
"current": { "text": "_total", "value": "_total" },
"hide": 0,
"includeAll": false,
"label": "Counter suffix (OTel→Prom)",
"multi": false,
"name": "counter_suffix",
"options": [
{ "selected": true, "text": "_total", "value": "_total" },
{ "selected": false, "text": "(none)", "value": "" }
],
"query": "_total,",
"type": "custom"
}
]
},
"time": { "from": "now-6h", "to": "now" },
"timepicker": {},
"timezone": "",
"title": "Dodex Indexer",
"uid": "dodex-indexer",
"version": 1,
"weekStart": "",
"panels": [
{
"type": "row",
"title": "Overview — health at a glance",
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 0 },
"id": 1,
"panels": []
},
{
"type": "stat",
"title": "Projection backlog",
"description": "raw_events rows waiting for the projection loop (typed + decoded, processed_at NULL).",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 4, "w": 4, "x": 0, "y": 1 },
"id": 2,
"fieldConfig": {
"defaults": {
"unit": "short",
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 500 },
{ "color": "red", "value": 5000 }
]
}
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": { "calcs": ["lastNotNull"], "fields": "", "values": false },
"textMode": "auto"
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(indexer_projection_backlog{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "backlog",
"range": true,
"refId": "A"
}
]
},
{
"type": "stat",
"title": "Projection lag",
"description": "Wall-clock age of the oldest eligible-but-unprojected raw_events row; read-model staleness.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 4, "w": 4, "x": 4, "y": 1 },
"id": 3,
"fieldConfig": {
"defaults": {
"unit": "s",
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 30 },
{ "color": "red", "value": 120 }
]
}
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": { "calcs": ["lastNotNull"], "fields": "", "values": false },
"textMode": "auto"
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_projection_lag_seconds{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "lag",
"range": true,
"refId": "A"
}
]
},
{
"type": "stat",
"title": "Capture cursor age",
"description": "Seconds since the capture cursor last advanced; 0 when capture has not started.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 4, "w": 4, "x": 8, "y": 1 },
"id": 4,
"fieldConfig": {
"defaults": {
"unit": "s",
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 120 },
{ "color": "red", "value": 300 }
]
}
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": { "calcs": ["lastNotNull"], "fields": "", "values": false },
"textMode": "auto"
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_capture_cursor_age_seconds{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "cursor age",
"range": true,
"refId": "A"
}
]
},
{
"type": "stat",
"title": "Inference markets — visible",
"description": "Inference markets with last_reconciled_at stamped (served by the API).",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 4, "w": 4, "x": 12, "y": 1 },
"id": 5,
"fieldConfig": {
"defaults": {
"unit": "short",
"thresholds": {
"mode": "absolute",
"steps": [{ "color": "green", "value": null }]
}
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": { "calcs": ["lastNotNull"], "fields": "", "values": false },
"textMode": "auto"
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(indexer_inference_markets{state=\"visible\",job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "visible",
"range": true,
"refId": "A"
}
]
},
{
"type": "stat",
"title": "Inference markets — failing",
"description": "Invisible inference markets with a recorded reconcile failure (ABI drift, never-deployed / wrong-dApp residual). Any non-zero value warrants a look.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 4, "w": 4, "x": 16, "y": 1 },
"id": 6,
"fieldConfig": {
"defaults": {
"unit": "short",
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "red", "value": 1 }
]
}
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": { "calcs": ["lastNotNull"], "fields": "", "values": false },
"textMode": "auto"
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(indexer_inference_markets{state=\"failing\",job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "failing",
"range": true,
"refId": "A"
}
]
},
{
"type": "stat",
"title": "Decode errors (total)",
"description": "Event bodies that failed to decode and were stored undecoded — distinct from a benign unknown/ambiguous event id. Non-zero means ABI drift or a malformed cell.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 4, "w": 4, "x": 20, "y": 1 },
"id": 7,
"fieldConfig": {
"defaults": {
"unit": "short",
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "red", "value": 1 }
]
}
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": { "calcs": ["lastNotNull"], "fields": "", "values": false },
"textMode": "auto"
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(indexer_decode_errors${counter_suffix}{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "decode errors",
"range": true,
"refId": "A"
}
]
},
{
"type": "row",
"title": "Ingestion — raw_events counters",
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 5 },
"id": 8,
"panels": []
},
{
"type": "timeseries",
"title": "OrderPlaced rate",
"description": "rate() of orders_created_event_cnt — OrderBook.OrderPlaced events across all markets and users.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 0, "y": 6 },
"id": 9,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(orders_created_event_cnt${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "OrderPlaced/s",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "PartialFill rate",
"description": "rate() of order_partially_filled_event_cnt — OrderBook.PartialFill events across all markets and users.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 8, "y": 6 },
"id": 10,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(order_partially_filled_event_cnt${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "PartialFill/s",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Cumulative event totals",
"description": "Raw monotonic counters (recovered from raw_events after restart): total OrderPlaced and PartialFill events.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 16, "y": 6 },
"id": 11,
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": { "drawStyle": "line", "fillOpacity": 0, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["lastNotNull"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(orders_created_event_cnt${counter_suffix}{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "OrderPlaced total",
"range": true,
"refId": "A"
},
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(order_partially_filled_event_cnt${counter_suffix}{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "PartialFill total",
"range": true,
"refId": "B"
}
]
},
{
"type": "row",
"title": "Projection pipeline & resources",
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 14 },
"id": 12,
"panels": []
},
{
"type": "timeseries",
"title": "Projection backlog",
"description": "raw_events rows waiting for the projection loop (typed + decoded, processed_at NULL).",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 0, "y": 15 },
"id": 13,
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": { "drawStyle": "line", "fillOpacity": 15, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "sum(indexer_projection_backlog{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "backlog",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Projection lag (seconds)",
"description": "Wall-clock age of the oldest eligible-but-unprojected raw_events row.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 8, "y": 15 },
"id": 14,
"fieldConfig": {
"defaults": {
"unit": "s",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 30 },
{ "color": "red", "value": 120 }
]
}
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_projection_lag_seconds{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "lag",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Capture cursor age (seconds)",
"description": "Seconds since the capture cursor last advanced. Small here while projection lag is large = capture healthy, projection behind.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 16, "y": 15 },
"id": 15,
"fieldConfig": {
"defaults": {
"unit": "s",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 120 },
{ "color": "red", "value": 300 }
]
}
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_capture_cursor_age_seconds{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "cursor age",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Projection fallbacks rate",
"description": "rate() of indexer_projection_fallbacks — batches that aborted the optimistic pass and replayed with per-row savepoints. A climbing rate means the fast path is routinely aborting.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 0, "y": 23 },
"id": 16,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(indexer_projection_fallbacks${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "fallbacks/s",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "DB pool connections",
"description": "sqlx DB pool connections by state (in_use / idle). Backlog rising + in_use at max = projection stalled on connection exhaustion.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 8, "y": 23 },
"id": 17,
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": { "drawStyle": "line", "fillOpacity": 25, "lineWidth": 1, "showPoints": "never", "stacking": { "group": "A", "mode": "normal" } },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": [
{ "matcher": { "id": "byName", "options": "in_use" }, "properties": [{ "id": "color", "value": { "fixedColor": "orange", "mode": "fixed" } }] },
{ "matcher": { "id": "byName", "options": "idle" }, "properties": [{ "id": "color", "value": { "fixedColor": "green", "mode": "fixed" } }] }
]
},
"options": {
"legend": { "calcs": ["lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "indexer_db_pool_connections{job=~\"$job\",instance=~\"$instance\"}",
"legendFormat": "{{state}}",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Decode failures rate",
"description": "rate() of indexer_decode_errors (hard decode failures — ABI drift / malformed cell) and indexer_decode_ambiguous_collisions (a colliding event id with no dst route — should be flat zero; non-zero means a new colliding ABI was added without a decoder dst route, and those events are silently dropped). Both leave the row undecoded and skipped by projection.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 16, "y": 23 },
"id": 18,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "red", "value": 0.001 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(indexer_decode_errors${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "decode errors/s",
"range": true,
"refId": "A"
},
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(indexer_decode_ambiguous_collisions${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "ambiguous collisions/s",
"range": true,
"refId": "B"
}
]
},
{
"type": "row",
"title": "Inference markets",
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 31 },
"id": 19,
"panels": []
},
{
"type": "timeseries",
"title": "Markets by lifecycle state",
"description": "indexer_inference_markets{state}: discovering (seeded, not yet visible), visible (served by the API), failing (invisible with a recorded reconcile failure).",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 0, "y": 32 },
"id": 20,
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": { "drawStyle": "line", "fillOpacity": 25, "lineWidth": 1, "showPoints": "never", "stacking": { "group": "A", "mode": "normal" } },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": [
{ "matcher": { "id": "byName", "options": "visible" }, "properties": [{ "id": "color", "value": { "fixedColor": "green", "mode": "fixed" } }] },
{ "matcher": { "id": "byName", "options": "discovering" }, "properties": [{ "id": "color", "value": { "fixedColor": "yellow", "mode": "fixed" } }] },
{ "matcher": { "id": "byName", "options": "failing" }, "properties": [{ "id": "color", "value": { "fixedColor": "red", "mode": "fixed" } }] }
]
},
"options": {
"legend": { "calcs": ["lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "indexer_inference_markets{job=~\"$job\",instance=~\"$instance\"}",
"legendFormat": "{{state}}",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Resting orders by status",
"description": "indexer_inference_orders{status}: open (live order-book depth), filled, cancelled.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 8, "y": 32 },
"id": 21,
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": { "drawStyle": "line", "fillOpacity": 25, "lineWidth": 1, "showPoints": "never", "stacking": { "group": "A", "mode": "normal" } },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
},
"overrides": [
{ "matcher": { "id": "byName", "options": "open" }, "properties": [{ "id": "color", "value": { "fixedColor": "green", "mode": "fixed" } }] },
{ "matcher": { "id": "byName", "options": "filled" }, "properties": [{ "id": "color", "value": { "fixedColor": "blue", "mode": "fixed" } }] },
{ "matcher": { "id": "byName", "options": "cancelled" }, "properties": [{ "id": "color", "value": { "fixedColor": "orange", "mode": "fixed" } }] }
]
},
"options": {
"legend": { "calcs": ["lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "indexer_inference_orders{job=~\"$job\",instance=~\"$instance\"}",
"legendFormat": "{{status}}",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Reconcile failures rate",
"description": "rate() of indexer_inference_reconcile_failures — hard Err outcomes from a discovery or refresh tick (excludes the benign NoBoc skip). A climbing rate points at a getter ABI mismatch or a persistently unreachable dApp. Note: counts per-book Err only, not a tick-level query failure.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 16, "y": 32 },
"id": 22,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "red", "value": 0.001 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(indexer_inference_reconcile_failures${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "reconcile failures/s",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Reference price lag (seconds)",
"description": "indexer_inference_reference_price_lag_seconds — age of the most stale reference_price_at across visible markets; price-refresh (Queue B) staleness.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 0, "y": 40 },
"id": 23,
"fieldConfig": {
"defaults": {
"unit": "s",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "yellow", "value": 3600 }, { "color": "red", "value": 86400 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_inference_reference_price_lag_seconds{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "price lag",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Sweep lag (seconds)",
"description": "indexer_inference_sweep_lag_seconds — age of the most stale last_swept_at across visible markets; order-book-depth staleness (phantom-liquidity risk).",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 8, "y": 40 },
"id": 24,
"fieldConfig": {
"defaults": {
"unit": "s",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "yellow", "value": 300 }, { "color": "red", "value": 1800 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_inference_sweep_lag_seconds{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "sweep lag",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Orphans dropped rate",
"description": "rate() of indexer_inference_orphans_dropped — inference Filled/OrderCancelled events dead-lettered because their parent OrderPlaced never arrived within the orphan cutoff.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 16, "y": 40 },
"id": 25,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "red", "value": 0.001 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(indexer_inference_orphans_dropped${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "orphans dropped/s",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Wedged books (fail-closed 503, should be 0)",
"description": "indexer_inference_wedged_books — visible inference books with an unprojected raw_events row under their address; the read gate returns MarketInconsistent (503) for tokenContract live-SELL lookups on such a book until the row clears (a note=, side=BUY, or non-LIVE read still returns 200). A sustained non-zero value usually means a deployed contract upgrade outran the indexer's ABI. NOTE: this gauge freezes during a DB outage (its refresh query fails) — correlate with 'Metrics-refresh failures rate'.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 0, "y": 48 },
"id": 26,
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "red", "value": 1 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "max(indexer_inference_wedged_books{job=~\"$job\",instance=~\"$instance\"})",
"legendFormat": "wedged books",
"range": true,
"refId": "A"
}
]
},
{
"type": "timeseries",
"title": "Metrics-refresh failures rate",
"description": "rate() of indexer_metrics_refresh_failures — DB-query failures inside the metrics-refresh loop itself. A rising rate means the loop cannot read the DB, so every gauge it feeds (projection backlog/lag, capture cursor age, inference markets/orders/lags, wedged books) is frozen at its last value, not merely quiet. Pair any gauge alert with this signal so a frozen gauge during an outage is not read as healthy.",
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"gridPos": { "h": 8, "w": 8, "x": 8, "y": 48 },
"id": 27,
"fieldConfig": {
"defaults": {
"unit": "ops",
"custom": { "drawStyle": "line", "fillOpacity": 10, "lineWidth": 1, "showPoints": "never" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }, { "color": "red", "value": 0.001 }] }
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "lastNotNull", "max"], "displayMode": "table", "placement": "bottom", "showLegend": true },
"tooltip": { "mode": "multi", "sort": "desc" }
},
"targets": [
{
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"editorMode": "code",
"expr": "rate(indexer_metrics_refresh_failures${counter_suffix}{job=~\"$job\",instance=~\"$instance\"}[$__rate_interval])",
"legendFormat": "refresh failures/s",
"range": true,
"refId": "A"
}
]
}
]
}