1
- <script lang="ts">
2
- export enum columnName {
3
- ENDPOINTNAME = " name" ,
4
- QUEUELENGTH = " queueLength" ,
5
- THROUGHPUT = " throughput" ,
6
- SCHEDULEDRETRIES = " retries" ,
7
- PROCESSINGTIME = " processingTime" ,
8
- CRITICALTIME = " criticalTime" ,
9
- }
10
- </script >
11
1
<script setup lang="ts">
12
2
import { ref , computed } from " vue" ;
13
3
import { RouterLink } from " vue-router" ;
@@ -19,6 +9,7 @@ import { storeToRefs } from "pinia";
19
9
import type { GroupedEndpoint , Endpoint } from " @/resources/MonitoringEndpoint" ;
20
10
import routeLinks from " @/router/routeLinks" ;
21
11
import { Tippy } from " vue-tippy" ;
12
+ import { CriticalTime , EndpointName , ProcessingTime , QueueLength , ScheduledRetries , Throughput } from " @/resources/MonitoringResources" ;
22
13
23
14
const settings = defineProps <{
24
15
endpoint: GroupedEndpoint | Endpoint ;
@@ -41,7 +32,7 @@ const criticalTimeGraphDuration = computed(() => formatGraphDuration(endpoint.va
41
32
</script >
42
33
43
34
<template >
44
- <div role =" gridcell" :aria-label =" columnName.ENDPOINTNAME " class =" table-first-col endpoint-name name-overview" >
35
+ <div role =" gridcell" :aria-label =" EndpointName.name " class =" table-first-col endpoint-name name-overview" >
45
36
<div class =" box-header with-status" >
46
37
<div :aria-label =" shortName" class =" no-side-padding lead righ-side-ellipsis endpoint-details-link" >
47
38
<tippy :aria-label =" endpoint.name" :delay =" [700, 0]" >
@@ -78,12 +69,12 @@ const criticalTimeGraphDuration = computed(() => formatGraphDuration(endpoint.va
78
69
</div >
79
70
</div >
80
71
<!-- Queue Length-->
81
- <div role =" gridcell" :aria-label =" columnName.QUEUELENGTH " class =" table-col" >
72
+ <div role =" gridcell" :aria-label =" QueueLength.name " class =" table-col" >
82
73
<div class =" box-header" >
83
74
<div class =" no-side-padding" >
84
75
<SmallGraph
85
76
role =" img"
86
- :aria-label =" columnName.QUEUELENGTH "
77
+ :aria-label =" QueueLength.name "
87
78
:type =" 'queue-length'"
88
79
:isdurationgraph =" false"
89
80
:plotdata =" endpoint.metrics.queueLength"
@@ -100,12 +91,12 @@ const criticalTimeGraphDuration = computed(() => formatGraphDuration(endpoint.va
100
91
</div >
101
92
</div >
102
93
<!-- Throughput-->
103
- <div role =" gridcell" :aria-label =" columnName.THROUGHPUT " class =" table-col" >
94
+ <div role =" gridcell" :aria-label =" Throughput.name " class =" table-col" >
104
95
<div class =" box-header" >
105
96
<div class =" no-side-padding" >
106
97
<SmallGraph
107
98
role =" img"
108
- :aria-label =" columnName.THROUGHPUT "
99
+ :aria-label =" Throughput.name "
109
100
:type =" 'throughput'"
110
101
:isdurationgraph =" false"
111
102
:plotdata =" endpoint.metrics.throughput"
@@ -122,19 +113,10 @@ const criticalTimeGraphDuration = computed(() => formatGraphDuration(endpoint.va
122
113
</div >
123
114
</div >
124
115
<!-- Scheduled Retries-->
125
- <div role =" gridcell" :aria-label =" columnName.SCHEDULEDRETRIES " class =" table-col" >
116
+ <div role =" gridcell" :aria-label =" ScheduledRetries.name " class =" table-col" >
126
117
<div class =" box-header" >
127
118
<div class =" no-side-padding" >
128
- <SmallGraph
129
- role =" img"
130
- :aria-label =" columnName.SCHEDULEDRETRIES"
131
- :type =" 'retries'"
132
- :isdurationgraph =" false"
133
- :plotdata =" endpoint.metrics.retries"
134
- :minimumyaxis =" smallGraphsMinimumYAxis.retries"
135
- :avglabelcolor =" '#CC1252'"
136
- :metricsuffix =" 'MSGS/S'"
137
- />
119
+ <SmallGraph role =" img" :aria-label =" ScheduledRetries.name" :type =" 'retries'" :isdurationgraph =" false" :plotdata =" endpoint.metrics.retries" :minimumyaxis =" smallGraphsMinimumYAxis.retries" :avglabelcolor =" '#CC1252'" :metricsuffix =" 'MSGS/S'" />
138
120
</div >
139
121
<div role =" text" aria-label =" sparkline" class =" no-side-padding sparkline-value" >
140
122
{{ endpoint.isStale == true || endpoint.isScMonitoringDisconnected == true ? "" : formatGraphDecimal(endpoint.metrics.retries, 2) }}
@@ -144,10 +126,10 @@ const criticalTimeGraphDuration = computed(() => formatGraphDuration(endpoint.va
144
126
</div >
145
127
</div >
146
128
<!-- Processing Time-->
147
- <div role =" gridcell" :aria-label =" columnName.PROCESSINGTIME " class =" table-col" >
129
+ <div role =" gridcell" :aria-label =" ProcessingTime.name " class =" table-col" >
148
130
<div class =" box-header" >
149
131
<div class =" no-side-padding" >
150
- <SmallGraph role =" img" :aria-label =" columnName.PROCESSINGTIME " :type =" 'processing-time'" :isdurationgraph =" true" :plotdata =" endpoint.metrics.processingTime" :minimumyaxis =" smallGraphsMinimumYAxis.processingTime" :avglabelcolor =" '#258135'" />
132
+ <SmallGraph role =" img" :aria-label =" ProcessingTime.name " :type =" 'processing-time'" :isdurationgraph =" true" :plotdata =" endpoint.metrics.processingTime" :minimumyaxis =" smallGraphsMinimumYAxis.processingTime" :avglabelcolor =" '#258135'" />
151
133
</div >
152
134
<div role =" text" aria-label =" sparkline" class =" no-side-padding sparkline-value" >
153
135
{{ endpoint.isStale == true || endpoint.isScMonitoringDisconnected == true ? "" : processingTimeGraphDuration.value }}
@@ -158,10 +140,10 @@ const criticalTimeGraphDuration = computed(() => formatGraphDuration(endpoint.va
158
140
</div >
159
141
</div >
160
142
<!-- Critical Time-->
161
- <div role =" gridcell" :aria-label =" columnName.CRITICALTIME " class =" table-col" >
143
+ <div role =" gridcell" :aria-label =" CriticalTime.name " class =" table-col" >
162
144
<div class =" box-header" >
163
145
<div class =" no-side-padding" >
164
- <SmallGraph role =" img" :aria-label =" columnName.CRITICALTIME " :type =" 'critical-time'" :isdurationgraph =" true" :plotdata =" endpoint.metrics.criticalTime" :minimumyaxis =" smallGraphsMinimumYAxis.criticalTime" :avglabelcolor =" '#2700CB'" />
146
+ <SmallGraph role =" img" :aria-label =" CriticalTime.name " :type =" 'critical-time'" :isdurationgraph =" true" :plotdata =" endpoint.metrics.criticalTime" :minimumyaxis =" smallGraphsMinimumYAxis.criticalTime" :avglabelcolor =" '#2700CB'" />
165
147
</div >
166
148
<div role =" text" aria-label =" sparkline" class =" no-side-padding sparkline-value" :class =" { negative: parseFloat(criticalTimeGraphDuration.value) < 0 }" >
167
149
{{ endpoint.isStale == true || endpoint.isScMonitoringDisconnected == true ? "" : criticalTimeGraphDuration.value }}
0 commit comments