@centreon/ui 24.6.2 → 24.6.4
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/package.json +1 -1
- package/src/Graph/BarChart/BarChart.cypress.spec.tsx +233 -0
- package/src/Graph/BarChart/BarChart.stories.tsx +213 -0
- package/src/Graph/BarChart/BarChart.tsx +101 -0
- package/src/Graph/BarChart/BarGroup.tsx +246 -0
- package/src/Graph/BarChart/BarStack.tsx +126 -0
- package/src/Graph/BarChart/ResponsiveBarChart.tsx +263 -0
- package/src/Graph/BarChart/SingleBar.tsx +62 -0
- package/src/Graph/BarChart/Tooltip/BarChartTooltip.tsx +122 -0
- package/src/Graph/BarChart/Tooltip/useBarChartTooltipStyles.ts +28 -0
- package/src/Graph/BarChart/atoms.ts +5 -0
- package/src/Graph/BarChart/models.ts +21 -0
- package/src/Graph/BarChart/useBarChartStyles.tsx +5 -0
- package/src/Graph/BarChart/useBarStack.ts +114 -0
- package/src/Graph/BarChart/useSingleBar.ts +199 -0
- package/src/Graph/Gauge/Gauge.cypress.spec.tsx +1 -1
- package/src/Graph/Gauge/Gauge.stories.tsx +1 -1
- package/src/Graph/LineChart/LineChart.cypress.spec.tsx +4 -4
- package/src/Graph/LineChart/LineChart.styles.ts +0 -5
- package/src/Graph/LineChart/LineChart.tsx +118 -122
- package/src/Graph/LineChart/index.stories.tsx +12 -12
- package/src/Graph/SingleBar/SingleBar.cypress.spec.tsx +1 -1
- package/src/Graph/SingleBar/SingleBar.stories.tsx +1 -1
- package/src/Graph/Text/Text.cypress.spec.tsx +1 -1
- package/src/Graph/Text/Text.stories.tsx +1 -1
- package/src/Graph/common/Axes/index.tsx +40 -13
- package/src/Graph/common/BaseChart/BaseChart.tsx +25 -6
- package/src/Graph/common/BaseChart/ChartSvgWrapper.tsx +15 -4
- package/src/Graph/{LineChart → common/BaseChart}/Header/index.tsx +3 -3
- package/src/Graph/common/BaseChart/Header/models.ts +4 -0
- package/src/Graph/common/BaseChart/Header/useHeaderStyles.ts +9 -0
- package/src/Graph/common/BaseChart/useBaseChartStyles.ts +6 -0
- package/src/Graph/{LineChart/BasicComponents → common/Thresholds}/ThresholdLine.tsx +20 -10
- package/src/Graph/{LineChart/BasicComponents → common/Thresholds}/Thresholds.tsx +8 -4
- package/src/Graph/common/timeSeries/index.ts +33 -11
- package/src/Graph/common/timeSeries/models.ts +1 -0
- package/src/Graph/common/useTooltipStyles.ts +1 -0
- package/src/Graph/mockedData/pingService.json +203 -0
- package/src/Graph/mockedData/pingServiceMixedStacked.json +203 -0
- package/src/Graph/mockedData/pingServiceStacked.json +203 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/annotationData.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/curvesWithSameColor.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/exclusionPeriodFirstPeriod.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/exclusionPeriodSecondPeriod.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/exclusionPeriodThirdPeriod.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastDay.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastDayAreaStack.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastDayForward.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastDayThreshold.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastDayWithIncompleteValues.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastDayWithNullValues.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastMonth.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/lastWeek.json +0 -0
- /package/src/Graph/{LineChart/mockedData → mockedData}/zoomPreview.json +0 -0
|
@@ -2,10 +2,11 @@ import { equals } from 'ramda';
|
|
|
2
2
|
|
|
3
3
|
import { useTheme } from '@mui/material';
|
|
4
4
|
|
|
5
|
-
import { margin } from '
|
|
5
|
+
import { margin } from '../../LineChart/common';
|
|
6
6
|
|
|
7
7
|
interface Props {
|
|
8
8
|
hideTooltip: () => void;
|
|
9
|
+
isHorizontal: boolean;
|
|
9
10
|
label: string;
|
|
10
11
|
showTooltip: (args) => void;
|
|
11
12
|
thresholdType: string;
|
|
@@ -21,7 +22,8 @@ export const ThresholdLine = ({
|
|
|
21
22
|
thresholdType,
|
|
22
23
|
showTooltip,
|
|
23
24
|
hideTooltip,
|
|
24
|
-
width
|
|
25
|
+
width,
|
|
26
|
+
isHorizontal
|
|
25
27
|
}: Props): JSX.Element => {
|
|
26
28
|
const theme = useTheme();
|
|
27
29
|
|
|
@@ -38,6 +40,20 @@ export const ThresholdLine = ({
|
|
|
38
40
|
? theme.palette.warning.main
|
|
39
41
|
: theme.palette.error.main;
|
|
40
42
|
|
|
43
|
+
const coordinates = isHorizontal
|
|
44
|
+
? {
|
|
45
|
+
x1: 0,
|
|
46
|
+
x2: width,
|
|
47
|
+
y1: scaledValue,
|
|
48
|
+
y2: scaledValue
|
|
49
|
+
}
|
|
50
|
+
: {
|
|
51
|
+
x1: scaledValue,
|
|
52
|
+
x2: scaledValue,
|
|
53
|
+
y1: 0,
|
|
54
|
+
y2: width
|
|
55
|
+
};
|
|
56
|
+
|
|
41
57
|
return (
|
|
42
58
|
<>
|
|
43
59
|
<line
|
|
@@ -45,21 +61,15 @@ export const ThresholdLine = ({
|
|
|
45
61
|
stroke={lineColor}
|
|
46
62
|
strokeDasharray="5,5"
|
|
47
63
|
strokeWidth={2}
|
|
48
|
-
|
|
49
|
-
x2={width}
|
|
50
|
-
y1={scaledValue}
|
|
51
|
-
y2={scaledValue}
|
|
64
|
+
{...coordinates}
|
|
52
65
|
/>
|
|
53
66
|
<line
|
|
54
67
|
data-testid={`${thresholdType}-line-${value}-tooltip`}
|
|
55
68
|
stroke="transparent"
|
|
56
69
|
strokeWidth={5}
|
|
57
|
-
x1={0}
|
|
58
|
-
x2={width}
|
|
59
|
-
y1={scaledValue}
|
|
60
|
-
y2={scaledValue}
|
|
61
70
|
onMouseEnter={onMouseEnter}
|
|
62
71
|
onMouseLeave={hideTooltip}
|
|
72
|
+
{...coordinates}
|
|
63
73
|
/>
|
|
64
74
|
</>
|
|
65
75
|
);
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { equals, isNil } from 'ramda';
|
|
2
2
|
|
|
3
|
-
import { getUnits, getYScale } from '
|
|
4
|
-
import { Line } from '
|
|
5
|
-
import { Thresholds as ThresholdsModel } from '
|
|
3
|
+
import { getUnits, getYScale } from '../timeSeries';
|
|
4
|
+
import { Line } from '../timeSeries/models';
|
|
5
|
+
import { Thresholds as ThresholdsModel } from '../models';
|
|
6
6
|
|
|
7
7
|
import { ThresholdLine } from './ThresholdLine';
|
|
8
8
|
|
|
9
9
|
interface Props {
|
|
10
10
|
displayedLines: Array<Line>;
|
|
11
11
|
hideTooltip: () => void;
|
|
12
|
+
isHorizontal?: boolean;
|
|
12
13
|
leftScale: (value: number) => number;
|
|
13
14
|
rightScale: (value: number) => number;
|
|
14
15
|
showTooltip: (props) => void;
|
|
@@ -25,7 +26,8 @@ const Thresholds = ({
|
|
|
25
26
|
displayedLines,
|
|
26
27
|
thresholdUnit,
|
|
27
28
|
showTooltip,
|
|
28
|
-
hideTooltip
|
|
29
|
+
hideTooltip,
|
|
30
|
+
isHorizontal = true
|
|
29
31
|
}: Props): JSX.Element => {
|
|
30
32
|
const [firstUnit, secondUnit, thirdUnit] = getUnits(
|
|
31
33
|
displayedLines as Array<Line>
|
|
@@ -49,6 +51,7 @@ const Thresholds = ({
|
|
|
49
51
|
{thresholds.warning.map(({ value, label }) => (
|
|
50
52
|
<ThresholdLine
|
|
51
53
|
hideTooltip={hideTooltip}
|
|
54
|
+
isHorizontal={isHorizontal}
|
|
52
55
|
key={`warning-${value}`}
|
|
53
56
|
label={label}
|
|
54
57
|
showTooltip={showTooltip}
|
|
@@ -61,6 +64,7 @@ const Thresholds = ({
|
|
|
61
64
|
{thresholds.critical.map(({ value, label }) => (
|
|
62
65
|
<ThresholdLine
|
|
63
66
|
hideTooltip={hideTooltip}
|
|
67
|
+
isHorizontal={isHorizontal}
|
|
64
68
|
key={`critical-${value}`}
|
|
65
69
|
label={label}
|
|
66
70
|
showTooltip={showTooltip}
|
|
@@ -135,9 +135,10 @@ const toLine = ({
|
|
|
135
135
|
metric_id,
|
|
136
136
|
minimum_value,
|
|
137
137
|
name: legend,
|
|
138
|
-
stackOrder:
|
|
139
|
-
|
|
140
|
-
|
|
138
|
+
stackOrder:
|
|
139
|
+
equals(ds_data.ds_stack, '1') || equals(ds_data.ds_stack, true)
|
|
140
|
+
? parseInt(ds_data.ds_order || '0', 10)
|
|
141
|
+
: null,
|
|
141
142
|
transparency: ds_data.ds_transparency,
|
|
142
143
|
unit
|
|
143
144
|
});
|
|
@@ -353,7 +354,8 @@ const getScale = ({
|
|
|
353
354
|
thresholds,
|
|
354
355
|
isCenteredZero,
|
|
355
356
|
scale,
|
|
356
|
-
scaleLogarithmicBase
|
|
357
|
+
scaleLogarithmicBase,
|
|
358
|
+
isHorizontal
|
|
357
359
|
}): ScaleLinear<number, number> => {
|
|
358
360
|
const isLogScale = equals(scale, 'logarithmic');
|
|
359
361
|
const minValue = Math.min(
|
|
@@ -370,6 +372,7 @@ const getScale = ({
|
|
|
370
372
|
const scaleType = getScaleType(scale);
|
|
371
373
|
|
|
372
374
|
const upperRangeValue = minValue === maxValue && maxValue === 0 ? height : 0;
|
|
375
|
+
const range = [height, upperRangeValue];
|
|
373
376
|
|
|
374
377
|
if (isCenteredZero) {
|
|
375
378
|
const greatestValue = Math.max(Math.abs(maxValue), Math.abs(minValue));
|
|
@@ -377,14 +380,14 @@ const getScale = ({
|
|
|
377
380
|
return scaleType<number>({
|
|
378
381
|
base: scaleLogarithmicBase || 2,
|
|
379
382
|
domain: [-greatestValue, greatestValue],
|
|
380
|
-
range:
|
|
383
|
+
range: isHorizontal ? range : range.reverse()
|
|
381
384
|
});
|
|
382
385
|
}
|
|
383
386
|
|
|
384
387
|
return scaleType<number>({
|
|
385
388
|
base: scaleLogarithmicBase || 2,
|
|
386
389
|
domain: [isLogScale ? 0.001 : minValue, maxValue],
|
|
387
|
-
range:
|
|
390
|
+
range: isHorizontal ? range : range.reverse()
|
|
388
391
|
});
|
|
389
392
|
};
|
|
390
393
|
|
|
@@ -396,9 +399,10 @@ const getLeftScale = ({
|
|
|
396
399
|
thresholdUnit,
|
|
397
400
|
isCenteredZero,
|
|
398
401
|
scale,
|
|
399
|
-
scaleLogarithmicBase
|
|
402
|
+
scaleLogarithmicBase,
|
|
403
|
+
isHorizontal = true
|
|
400
404
|
}: AxeScale): ScaleLinear<number, number> => {
|
|
401
|
-
const [firstUnit, , thirdUnit] = getUnits(dataLines);
|
|
405
|
+
const [firstUnit, secondUnit, thirdUnit] = getUnits(dataLines);
|
|
402
406
|
|
|
403
407
|
const shouldApplyThresholds =
|
|
404
408
|
equals(thresholdUnit, firstUnit) ||
|
|
@@ -423,7 +427,9 @@ const getLeftScale = ({
|
|
|
423
427
|
|
|
424
428
|
const stackedValues = firstUnitHasStackedLines
|
|
425
429
|
? getStackedMetricValues({
|
|
426
|
-
lines: getSortedStackedLines(dataLines)
|
|
430
|
+
lines: getSortedStackedLines(dataLines).filter(
|
|
431
|
+
({ unit }) => !equals(unit, secondUnit)
|
|
432
|
+
),
|
|
427
433
|
timeSeries: dataTimeSeries
|
|
428
434
|
})
|
|
429
435
|
: [0];
|
|
@@ -432,6 +438,7 @@ const getLeftScale = ({
|
|
|
432
438
|
graphValues,
|
|
433
439
|
height: valueGraphHeight,
|
|
434
440
|
isCenteredZero,
|
|
441
|
+
isHorizontal,
|
|
435
442
|
scale,
|
|
436
443
|
scaleLogarithmicBase,
|
|
437
444
|
stackedValues,
|
|
@@ -449,6 +456,17 @@ const getXScale = ({
|
|
|
449
456
|
});
|
|
450
457
|
};
|
|
451
458
|
|
|
459
|
+
export const getXScaleBand = ({
|
|
460
|
+
dataTime,
|
|
461
|
+
valueWidth
|
|
462
|
+
}: Xscale): ReturnType<typeof Scale.scaleBand<number>> => {
|
|
463
|
+
return Scale.scaleBand({
|
|
464
|
+
domain: dataTime.map(getTime),
|
|
465
|
+
padding: 0.2,
|
|
466
|
+
range: [0, valueWidth]
|
|
467
|
+
});
|
|
468
|
+
};
|
|
469
|
+
|
|
452
470
|
const getRightScale = ({
|
|
453
471
|
dataLines,
|
|
454
472
|
dataTimeSeries,
|
|
@@ -457,7 +475,8 @@ const getRightScale = ({
|
|
|
457
475
|
thresholdUnit,
|
|
458
476
|
isCenteredZero,
|
|
459
477
|
scale,
|
|
460
|
-
scaleLogarithmicBase
|
|
478
|
+
scaleLogarithmicBase,
|
|
479
|
+
isHorizontal = true
|
|
461
480
|
}: AxeScale): ScaleLinear<number, number> => {
|
|
462
481
|
const [, secondUnit] = getUnits(dataLines);
|
|
463
482
|
|
|
@@ -475,7 +494,9 @@ const getRightScale = ({
|
|
|
475
494
|
|
|
476
495
|
const stackedValues = secondUnitHasStackedLines
|
|
477
496
|
? getStackedMetricValues({
|
|
478
|
-
lines: getSortedStackedLines(dataLines)
|
|
497
|
+
lines: getSortedStackedLines(dataLines).filter(({ unit }) =>
|
|
498
|
+
equals(unit, secondUnit)
|
|
499
|
+
),
|
|
479
500
|
timeSeries: dataTimeSeries
|
|
480
501
|
})
|
|
481
502
|
: [0];
|
|
@@ -484,6 +505,7 @@ const getRightScale = ({
|
|
|
484
505
|
graphValues,
|
|
485
506
|
height: valueGraphHeight,
|
|
486
507
|
isCenteredZero,
|
|
508
|
+
isHorizontal,
|
|
487
509
|
scale,
|
|
488
510
|
scaleLogarithmicBase,
|
|
489
511
|
stackedValues,
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
{
|
|
2
|
+
"global": {
|
|
3
|
+
"base": 1000,
|
|
4
|
+
"title": "Ping service"
|
|
5
|
+
},
|
|
6
|
+
"metrics": [
|
|
7
|
+
{
|
|
8
|
+
"metric_id": 2,
|
|
9
|
+
"metric": "Centreon-Server: pl",
|
|
10
|
+
"metric_legend": "Centreon-Server: pl",
|
|
11
|
+
"unit": "%",
|
|
12
|
+
"min": 0.0,
|
|
13
|
+
"max": 100.0,
|
|
14
|
+
"ds_data": {
|
|
15
|
+
"ds_color_line": "#F30B23",
|
|
16
|
+
"ds_color_area": "#F30B23",
|
|
17
|
+
"ds_filled": true,
|
|
18
|
+
"ds_invert": false,
|
|
19
|
+
"ds_legend": null,
|
|
20
|
+
"ds_stack": false,
|
|
21
|
+
"ds_order": 1,
|
|
22
|
+
"ds_transparency": 80.0,
|
|
23
|
+
"ds_color_line_mode": 0
|
|
24
|
+
},
|
|
25
|
+
"legend": "Centreon-Server: Packet Loss",
|
|
26
|
+
"stack": 0,
|
|
27
|
+
"warning_high_threshold": 20.0,
|
|
28
|
+
"critical_high_threshold": 50.0,
|
|
29
|
+
"warning_low_threshold": 0.0,
|
|
30
|
+
"critical_low_threshold": 0.0,
|
|
31
|
+
"ds_order": 1,
|
|
32
|
+
"data": [
|
|
33
|
+
0.0,
|
|
34
|
+
0.0,
|
|
35
|
+
0.0,
|
|
36
|
+
0.0,
|
|
37
|
+
0.0,
|
|
38
|
+
0.0,
|
|
39
|
+
0.0,
|
|
40
|
+
0.0,
|
|
41
|
+
0.0,
|
|
42
|
+
10.0,
|
|
43
|
+
20.0,
|
|
44
|
+
null,
|
|
45
|
+
null
|
|
46
|
+
],
|
|
47
|
+
"last_value": 0.0,
|
|
48
|
+
"minimum_value": null,
|
|
49
|
+
"maximum_value": 0.0,
|
|
50
|
+
"average_value": 0.0
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"metric_id": 1,
|
|
54
|
+
"metric": "Centreon-Server: rta",
|
|
55
|
+
"metric_legend": "Centreon-Server: rta",
|
|
56
|
+
"unit": "ms",
|
|
57
|
+
"min": 0.0,
|
|
58
|
+
"max": null,
|
|
59
|
+
"ds_data": {
|
|
60
|
+
"ds_color_line": "#29AFEE",
|
|
61
|
+
"ds_color_area": "#29AFEE",
|
|
62
|
+
"ds_filled": true,
|
|
63
|
+
"ds_invert": false,
|
|
64
|
+
"ds_legend": null,
|
|
65
|
+
"ds_stack": false,
|
|
66
|
+
"ds_order": 1,
|
|
67
|
+
"ds_transparency": 80.0,
|
|
68
|
+
"ds_color_line_mode": 0
|
|
69
|
+
},
|
|
70
|
+
"legend": "Centreon-Server: Round-Trip Average Time",
|
|
71
|
+
"stack": 0,
|
|
72
|
+
"warning_high_threshold": 200.0,
|
|
73
|
+
"critical_high_threshold": 400.0,
|
|
74
|
+
"warning_low_threshold": 0.0,
|
|
75
|
+
"critical_low_threshold": 0.0,
|
|
76
|
+
"ds_order": 1,
|
|
77
|
+
"data": [
|
|
78
|
+
0.04508,
|
|
79
|
+
0.0242,
|
|
80
|
+
0.03592,
|
|
81
|
+
0.01304,
|
|
82
|
+
0.025,
|
|
83
|
+
0.02748,
|
|
84
|
+
0.05296,
|
|
85
|
+
0.01864,
|
|
86
|
+
0.02688,
|
|
87
|
+
0.03676,
|
|
88
|
+
0.03696,
|
|
89
|
+
null,
|
|
90
|
+
null
|
|
91
|
+
],
|
|
92
|
+
"last_value": 0.04,
|
|
93
|
+
"minimum_value": null,
|
|
94
|
+
"maximum_value": null,
|
|
95
|
+
"average_value": 0.03
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"metric_id": 3,
|
|
99
|
+
"metric": "Centreon-Server: rtmax",
|
|
100
|
+
"metric_legend": "Centreon-Server: rtmax",
|
|
101
|
+
"unit": "ms",
|
|
102
|
+
"min": null,
|
|
103
|
+
"max": null,
|
|
104
|
+
"ds_data": {
|
|
105
|
+
"ds_color_line": "#525256",
|
|
106
|
+
"ds_color_area": "#525256",
|
|
107
|
+
"ds_filled": false,
|
|
108
|
+
"ds_invert": false,
|
|
109
|
+
"ds_legend": null,
|
|
110
|
+
"ds_stack": false,
|
|
111
|
+
"ds_order": 2,
|
|
112
|
+
"ds_transparency": 80.0,
|
|
113
|
+
"ds_color_line_mode": 0
|
|
114
|
+
},
|
|
115
|
+
"legend": "Centreon-Server: Round-Trip Maximum Time",
|
|
116
|
+
"stack": 0,
|
|
117
|
+
"warning_high_threshold": null,
|
|
118
|
+
"critical_high_threshold": null,
|
|
119
|
+
"warning_low_threshold": null,
|
|
120
|
+
"critical_low_threshold": null,
|
|
121
|
+
"ds_order": 2,
|
|
122
|
+
"data": [
|
|
123
|
+
0.11372,
|
|
124
|
+
0.05604,
|
|
125
|
+
0.08556,
|
|
126
|
+
0.02548,
|
|
127
|
+
0.05352,
|
|
128
|
+
0.05336,
|
|
129
|
+
0.109,
|
|
130
|
+
0.04112,
|
|
131
|
+
0.05504,
|
|
132
|
+
0.06812,
|
|
133
|
+
0.08644,
|
|
134
|
+
null,
|
|
135
|
+
null
|
|
136
|
+
],
|
|
137
|
+
"last_value": 0.09,
|
|
138
|
+
"minimum_value": null,
|
|
139
|
+
"maximum_value": 0.11,
|
|
140
|
+
"average_value": null
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
"metric_id": 4,
|
|
144
|
+
"metric": "Centreon-Server: rtmin",
|
|
145
|
+
"metric_legend": "Centreon-Server: rtmin",
|
|
146
|
+
"unit": "ms",
|
|
147
|
+
"min": null,
|
|
148
|
+
"max": null,
|
|
149
|
+
"ds_data": {
|
|
150
|
+
"ds_color_line": "#191777",
|
|
151
|
+
"ds_color_area": "#191777",
|
|
152
|
+
"ds_filled": false,
|
|
153
|
+
"ds_invert": false,
|
|
154
|
+
"ds_legend": null,
|
|
155
|
+
"ds_stack": false,
|
|
156
|
+
"ds_order": 2,
|
|
157
|
+
"ds_transparency": 80.0,
|
|
158
|
+
"ds_color_line_mode": 0
|
|
159
|
+
},
|
|
160
|
+
"legend": "Centreon-Server: Round-Trip Minimum Time",
|
|
161
|
+
"stack": 0,
|
|
162
|
+
"warning_high_threshold": null,
|
|
163
|
+
"critical_high_threshold": null,
|
|
164
|
+
"warning_low_threshold": null,
|
|
165
|
+
"critical_low_threshold": null,
|
|
166
|
+
"ds_order": 2,
|
|
167
|
+
"data": [
|
|
168
|
+
0.00984,
|
|
169
|
+
0.008,
|
|
170
|
+
0.00784,
|
|
171
|
+
0.00624,
|
|
172
|
+
0.00932,
|
|
173
|
+
0.01348,
|
|
174
|
+
0.01796,
|
|
175
|
+
0.0064,
|
|
176
|
+
0.01148,
|
|
177
|
+
0.01644,
|
|
178
|
+
0.01168,
|
|
179
|
+
null,
|
|
180
|
+
null
|
|
181
|
+
],
|
|
182
|
+
"last_value": 0.01,
|
|
183
|
+
"minimum_value": 0.01,
|
|
184
|
+
"maximum_value": null,
|
|
185
|
+
"average_value": null
|
|
186
|
+
}
|
|
187
|
+
],
|
|
188
|
+
"times": [
|
|
189
|
+
"2024-06-19T10:50:00+02:00",
|
|
190
|
+
"2024-06-19T10:55:00+02:00",
|
|
191
|
+
"2024-06-19T11:00:00+02:00",
|
|
192
|
+
"2024-06-19T11:05:00+02:00",
|
|
193
|
+
"2024-06-19T11:10:00+02:00",
|
|
194
|
+
"2024-06-19T11:15:00+02:00",
|
|
195
|
+
"2024-06-19T11:20:00+02:00",
|
|
196
|
+
"2024-06-19T11:25:00+02:00",
|
|
197
|
+
"2024-06-19T11:30:00+02:00",
|
|
198
|
+
"2024-06-19T11:35:00+02:00",
|
|
199
|
+
"2024-06-19T11:40:00+02:00",
|
|
200
|
+
"2024-06-19T11:45:00+02:00",
|
|
201
|
+
"2024-06-19T11:50:00+02:00"
|
|
202
|
+
]
|
|
203
|
+
}
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
{
|
|
2
|
+
"global": {
|
|
3
|
+
"base": 1000,
|
|
4
|
+
"title": "Ping service"
|
|
5
|
+
},
|
|
6
|
+
"metrics": [
|
|
7
|
+
{
|
|
8
|
+
"metric_id": 2,
|
|
9
|
+
"metric": "Centreon-Server: pl",
|
|
10
|
+
"metric_legend": "Centreon-Server: pl",
|
|
11
|
+
"unit": "%",
|
|
12
|
+
"min": 0.0,
|
|
13
|
+
"max": 100.0,
|
|
14
|
+
"ds_data": {
|
|
15
|
+
"ds_color_line": "#F30B23",
|
|
16
|
+
"ds_color_area": "#F30B23",
|
|
17
|
+
"ds_filled": true,
|
|
18
|
+
"ds_invert": false,
|
|
19
|
+
"ds_legend": null,
|
|
20
|
+
"ds_stack": true,
|
|
21
|
+
"ds_order": 1,
|
|
22
|
+
"ds_transparency": 80.0,
|
|
23
|
+
"ds_color_line_mode": 0
|
|
24
|
+
},
|
|
25
|
+
"legend": "Centreon-Server: Packet Loss",
|
|
26
|
+
"stack": 0,
|
|
27
|
+
"warning_high_threshold": 20.0,
|
|
28
|
+
"critical_high_threshold": 50.0,
|
|
29
|
+
"warning_low_threshold": 0.0,
|
|
30
|
+
"critical_low_threshold": 0.0,
|
|
31
|
+
"ds_order": 1,
|
|
32
|
+
"data": [
|
|
33
|
+
0.0,
|
|
34
|
+
0.0,
|
|
35
|
+
0.0,
|
|
36
|
+
0.0,
|
|
37
|
+
0.0,
|
|
38
|
+
0.0,
|
|
39
|
+
0.0,
|
|
40
|
+
0.0,
|
|
41
|
+
0.0,
|
|
42
|
+
10.0,
|
|
43
|
+
20.0,
|
|
44
|
+
null,
|
|
45
|
+
null
|
|
46
|
+
],
|
|
47
|
+
"last_value": 0.0,
|
|
48
|
+
"minimum_value": null,
|
|
49
|
+
"maximum_value": 0.0,
|
|
50
|
+
"average_value": 0.0
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"metric_id": 1,
|
|
54
|
+
"metric": "Centreon-Server: rta",
|
|
55
|
+
"metric_legend": "Centreon-Server: rta",
|
|
56
|
+
"unit": "ms",
|
|
57
|
+
"min": 0.0,
|
|
58
|
+
"max": null,
|
|
59
|
+
"ds_data": {
|
|
60
|
+
"ds_color_line": "#29AFEE",
|
|
61
|
+
"ds_color_area": "#29AFEE",
|
|
62
|
+
"ds_filled": true,
|
|
63
|
+
"ds_invert": false,
|
|
64
|
+
"ds_legend": null,
|
|
65
|
+
"ds_stack": false,
|
|
66
|
+
"ds_order": 1,
|
|
67
|
+
"ds_transparency": 80.0,
|
|
68
|
+
"ds_color_line_mode": 0
|
|
69
|
+
},
|
|
70
|
+
"legend": "Centreon-Server: Round-Trip Average Time",
|
|
71
|
+
"stack": 0,
|
|
72
|
+
"warning_high_threshold": 200.0,
|
|
73
|
+
"critical_high_threshold": 400.0,
|
|
74
|
+
"warning_low_threshold": 0.0,
|
|
75
|
+
"critical_low_threshold": 0.0,
|
|
76
|
+
"ds_order": 1,
|
|
77
|
+
"data": [
|
|
78
|
+
0.04508,
|
|
79
|
+
0.0242,
|
|
80
|
+
0.03592,
|
|
81
|
+
0.01304,
|
|
82
|
+
0.025,
|
|
83
|
+
0.02748,
|
|
84
|
+
0.05296,
|
|
85
|
+
0.01864,
|
|
86
|
+
0.02688,
|
|
87
|
+
0.03676,
|
|
88
|
+
0.03696,
|
|
89
|
+
null,
|
|
90
|
+
null
|
|
91
|
+
],
|
|
92
|
+
"last_value": 0.04,
|
|
93
|
+
"minimum_value": null,
|
|
94
|
+
"maximum_value": null,
|
|
95
|
+
"average_value": 0.03
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"metric_id": 3,
|
|
99
|
+
"metric": "Centreon-Server: rtmax",
|
|
100
|
+
"metric_legend": "Centreon-Server: rtmax",
|
|
101
|
+
"unit": "ms",
|
|
102
|
+
"min": null,
|
|
103
|
+
"max": null,
|
|
104
|
+
"ds_data": {
|
|
105
|
+
"ds_color_line": "#525256",
|
|
106
|
+
"ds_color_area": "#525256",
|
|
107
|
+
"ds_filled": false,
|
|
108
|
+
"ds_invert": false,
|
|
109
|
+
"ds_legend": null,
|
|
110
|
+
"ds_stack": true,
|
|
111
|
+
"ds_order": 2,
|
|
112
|
+
"ds_transparency": 80.0,
|
|
113
|
+
"ds_color_line_mode": 0
|
|
114
|
+
},
|
|
115
|
+
"legend": "Centreon-Server: Round-Trip Maximum Time",
|
|
116
|
+
"stack": 0,
|
|
117
|
+
"warning_high_threshold": null,
|
|
118
|
+
"critical_high_threshold": null,
|
|
119
|
+
"warning_low_threshold": null,
|
|
120
|
+
"critical_low_threshold": null,
|
|
121
|
+
"ds_order": 2,
|
|
122
|
+
"data": [
|
|
123
|
+
0.11372,
|
|
124
|
+
0.05604,
|
|
125
|
+
0.08556,
|
|
126
|
+
0.02548,
|
|
127
|
+
0.05352,
|
|
128
|
+
0.05336,
|
|
129
|
+
0.109,
|
|
130
|
+
0.04112,
|
|
131
|
+
0.05504,
|
|
132
|
+
0.06812,
|
|
133
|
+
0.08644,
|
|
134
|
+
null,
|
|
135
|
+
null
|
|
136
|
+
],
|
|
137
|
+
"last_value": 0.09,
|
|
138
|
+
"minimum_value": null,
|
|
139
|
+
"maximum_value": 0.11,
|
|
140
|
+
"average_value": null
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
"metric_id": 4,
|
|
144
|
+
"metric": "Centreon-Server: rtmin",
|
|
145
|
+
"metric_legend": "Centreon-Server: rtmin",
|
|
146
|
+
"unit": "ms",
|
|
147
|
+
"min": null,
|
|
148
|
+
"max": null,
|
|
149
|
+
"ds_data": {
|
|
150
|
+
"ds_color_line": "#191777",
|
|
151
|
+
"ds_color_area": "#191777",
|
|
152
|
+
"ds_filled": false,
|
|
153
|
+
"ds_invert": false,
|
|
154
|
+
"ds_legend": null,
|
|
155
|
+
"ds_stack": true,
|
|
156
|
+
"ds_order": 2,
|
|
157
|
+
"ds_transparency": 80.0,
|
|
158
|
+
"ds_color_line_mode": 0
|
|
159
|
+
},
|
|
160
|
+
"legend": "Centreon-Server: Round-Trip Minimum Time",
|
|
161
|
+
"stack": 0,
|
|
162
|
+
"warning_high_threshold": null,
|
|
163
|
+
"critical_high_threshold": null,
|
|
164
|
+
"warning_low_threshold": null,
|
|
165
|
+
"critical_low_threshold": null,
|
|
166
|
+
"ds_order": 2,
|
|
167
|
+
"data": [
|
|
168
|
+
0.00984,
|
|
169
|
+
0.008,
|
|
170
|
+
0.00784,
|
|
171
|
+
0.00624,
|
|
172
|
+
0.00932,
|
|
173
|
+
0.01348,
|
|
174
|
+
0.01796,
|
|
175
|
+
0.0064,
|
|
176
|
+
0.01148,
|
|
177
|
+
0.01644,
|
|
178
|
+
0.01168,
|
|
179
|
+
null,
|
|
180
|
+
null
|
|
181
|
+
],
|
|
182
|
+
"last_value": 0.01,
|
|
183
|
+
"minimum_value": 0.01,
|
|
184
|
+
"maximum_value": null,
|
|
185
|
+
"average_value": null
|
|
186
|
+
}
|
|
187
|
+
],
|
|
188
|
+
"times": [
|
|
189
|
+
"2024-06-19T10:50:00+02:00",
|
|
190
|
+
"2024-06-19T10:55:00+02:00",
|
|
191
|
+
"2024-06-19T11:00:00+02:00",
|
|
192
|
+
"2024-06-19T11:05:00+02:00",
|
|
193
|
+
"2024-06-19T11:10:00+02:00",
|
|
194
|
+
"2024-06-19T11:15:00+02:00",
|
|
195
|
+
"2024-06-19T11:20:00+02:00",
|
|
196
|
+
"2024-06-19T11:25:00+02:00",
|
|
197
|
+
"2024-06-19T11:30:00+02:00",
|
|
198
|
+
"2024-06-19T11:35:00+02:00",
|
|
199
|
+
"2024-06-19T11:40:00+02:00",
|
|
200
|
+
"2024-06-19T11:45:00+02:00",
|
|
201
|
+
"2024-06-19T11:50:00+02:00"
|
|
202
|
+
]
|
|
203
|
+
}
|