Skip to content

Commit fffc499

Browse files
ijardilliermashhurspickypg
authored
[125499] Add missing fields in monitoring logstash mb template mapping (#127053)
* [125499] Add missing fields in monitoring logstash mb template mapping * Add changelog, more missed fields and validate. --------- Co-authored-by: Mashhur <[email protected]> Co-authored-by: Chris Earle <[email protected]> Co-authored-by: Mashhur <[email protected]>
1 parent c468e3c commit fffc499

File tree

3 files changed

+250
-4
lines changed

3 files changed

+250
-4
lines changed

docs/changelog/127053.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pr: 127053
2+
summary: Add missing fields to the Logstash Stack Monitoring Template
3+
area: Monitoring
4+
type: enhancement
5+
issues:
6+
- 125499

x-pack/plugin/core/template-resources/src/main/resources/monitoring-logstash-mb.json

Lines changed: 243 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,80 @@
2828
},
2929
"heap_used_in_bytes": {
3030
"type": "long"
31+
},
32+
"heap_used_percent": {
33+
"type": "half_float"
3134
}
3235
}
3336
},
3437
"uptime_in_millis": {
3538
"type": "long"
39+
},
40+
"gc": {
41+
"properties": {
42+
"collectors": {
43+
"properties": {
44+
"young": {
45+
"properties": {
46+
"collection_count": {
47+
"type": "long"
48+
},
49+
"collection_time_in_millis": {
50+
"type": "long"
51+
}
52+
}
53+
},
54+
"old": {
55+
"properties": {
56+
"collection_count": {
57+
"type": "long"
58+
},
59+
"collection_time_in_millis": {
60+
"type": "long"
61+
}
62+
}
63+
}
64+
}
65+
}
66+
}
3667
}
3768
}
3869
},
3970
"logstash": {
4071
"properties": {
72+
"ephemeral_id": {
73+
"type": "keyword",
74+
"ignore_above": 1024
75+
},
76+
"host": {
77+
"type": "keyword",
78+
"ignore_above": 1024
79+
},
80+
"http_address": {
81+
"type": "keyword",
82+
"ignore_above": 1024
83+
},
84+
"name": {
85+
"type": "keyword",
86+
"ignore_above": 1024
87+
},
88+
"pipeline": {
89+
"properties": {
90+
"workers": {
91+
"type": "short"
92+
},
93+
"batch_size": {
94+
"type": "long"
95+
}
96+
}
97+
},
98+
"snapshot": {
99+
"type": "boolean"
100+
},
101+
"status": {
102+
"type": "keyword",
103+
"ignore_above": 1024
104+
},
41105
"uuid": {
42106
"ignore_above": 1024,
43107
"type": "keyword"
@@ -56,6 +120,12 @@
56120
"type": "double"
57121
}
58122
}
123+
},
124+
"max_file_descriptors": {
125+
"type": "long"
126+
},
127+
"open_file_descriptors": {
128+
"type": "long"
59129
}
60130
}
61131
},
@@ -189,6 +259,9 @@
189259
"type": "half_float"
190260
}
191261
}
262+
},
263+
"percent": {
264+
"type": "half_float"
192265
}
193266
}
194267
},
@@ -211,11 +284,19 @@
211284
},
212285
"cfs_quota_micros": {
213286
"type": "long"
287+
},
288+
"control_group": {
289+
"type": "keyword",
290+
"ignore_above": 1024
214291
}
215292
}
216293
},
217294
"cpuacct": {
218295
"properties": {
296+
"control_group": {
297+
"type": "keyword",
298+
"ignore_above": 1024
299+
},
219300
"usage_nanos": {
220301
"type": "long"
221302
}
@@ -248,6 +329,16 @@
248329
}
249330
}
250331
},
332+
"reloads": {
333+
"properties": {
334+
"failures": {
335+
"type": "long"
336+
},
337+
"successes": {
338+
"type": "long"
339+
}
340+
}
341+
},
251342
"timestamp": {
252343
"type": "date"
253344
}
@@ -292,10 +383,71 @@
292383
"graph": {
293384
"properties": {
294385
"vertices": {
295-
"type": "object"
386+
"type": "nested",
387+
"properties": {
388+
"config_name": {
389+
"type": "keyword",
390+
"ignore_above": 1024
391+
},
392+
"explicit_id": {
393+
"type": "boolean"
394+
},
395+
"id": {
396+
"type": "keyword",
397+
"ignore_above": 1024
398+
},
399+
"meta": {
400+
"properties": {
401+
"source": {
402+
"properties": {
403+
"column": {
404+
"type": "long"
405+
},
406+
"id": {
407+
"type": "keyword",
408+
"ignore_above": 1024
409+
},
410+
"line": {
411+
"type": "long"
412+
},
413+
"protocol": {
414+
"type": "keyword",
415+
"ignore_above": 1024
416+
}
417+
}
418+
}
419+
}
420+
},
421+
"plugin_type": {
422+
"type": "keyword",
423+
"ignore_above": 1024
424+
},
425+
"type": {
426+
"type": "keyword",
427+
"ignore_above": 1024
428+
}
429+
}
296430
},
297431
"edges": {
298-
"type": "object"
432+
"type": "nested",
433+
"properties": {
434+
"from": {
435+
"type": "keyword",
436+
"ignore_above": 1024
437+
},
438+
"id": {
439+
"type": "keyword",
440+
"ignore_above": 1024
441+
},
442+
"to": {
443+
"type": "keyword",
444+
"ignore_above": 1024
445+
},
446+
"type": {
447+
"type": "keyword",
448+
"ignore_above": 1024
449+
}
450+
}
299451
}
300452
}
301453
}
@@ -330,6 +482,14 @@
330482
}
331483
}
332484
}
485+
},
486+
"cluster": {
487+
"properties": {
488+
"id": {
489+
"type": "keyword",
490+
"ignore_above": 1024
491+
}
492+
}
333493
}
334494
}
335495
},
@@ -531,17 +691,73 @@
531691
"version": {
532692
"ignore_above": 1024,
533693
"type": "keyword"
694+
},
695+
"node": {
696+
"properties": {
697+
"name": {
698+
"type": "keyword",
699+
"ignore_above": 1024
700+
}
701+
}
534702
}
535703
}
536704
},
537705
"host": {
538706
"properties": {
539-
"name": {
707+
"architecture": {
708+
"type": "keyword",
709+
"ignore_above": 1024
710+
},
711+
"hostname": {
712+
"type": "keyword",
713+
"ignore_above": 1024
714+
},
715+
"id": {
540716
"type": "keyword",
541717
"ignore_above": 1024
542718
},
543719
"ip": {
544720
"type": "ip"
721+
},
722+
"mac": {
723+
"type": "keyword",
724+
"ignore_above": 1024
725+
},
726+
"name": {
727+
"type": "keyword",
728+
"ignore_above": 1024
729+
},
730+
"os": {
731+
"properties": {
732+
"build": {
733+
"type": "keyword",
734+
"ignore_above": 1024
735+
},
736+
"family": {
737+
"type": "keyword",
738+
"ignore_above": 1024
739+
},
740+
"kernel": {
741+
"type": "keyword",
742+
"ignore_above": 1024
743+
},
744+
"name": {
745+
"type": "keyword",
746+
"ignore_above": 1024
747+
},
748+
"platform": {
749+
"type": "keyword",
750+
"ignore_above": 1024
751+
},
752+
"type": {
753+
"type": "keyword",
754+
"ignore_above": 1024
755+
},
756+
"version": {
757+
"type": "keyword",
758+
"ignore_above": 1024
759+
}
760+
}
545761
}
546762
}
547763
},
@@ -578,6 +794,30 @@
578794
"cluster_uuid": {
579795
"type": "alias",
580796
"path": "logstash.elasticsearch.cluster.id"
797+
},
798+
"agent": {
799+
"properties": {
800+
"ephemeral_id": {
801+
"type": "keyword",
802+
"ignore_above": 1024
803+
},
804+
"id": {
805+
"type": "keyword",
806+
"ignore_above": 1024
807+
},
808+
"name": {
809+
"type": "keyword",
810+
"ignore_above": 1024
811+
},
812+
"type": {
813+
"type": "keyword",
814+
"ignore_above": 1024
815+
},
816+
"version": {
817+
"type": "keyword",
818+
"ignore_above": 1024
819+
}
820+
}
581821
}
582822
}
583823
},

x-pack/plugin/monitoring/src/main/java/org/elasticsearch/xpack/monitoring/MonitoringTemplateRegistry.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public class MonitoringTemplateRegistry extends IndexTemplateRegistry {
7777
* writes monitoring data in ECS format as of 8.0. These templates define the ECS schema as well as alias fields for the old monitoring
7878
* mappings that point to the corresponding ECS fields.
7979
*/
80-
public static final int STACK_MONITORING_REGISTRY_VERSION = 8_00_00_99 + 21;
80+
public static final int STACK_MONITORING_REGISTRY_VERSION = 8_00_00_99 + 22;
8181
private static final String STACK_MONITORING_REGISTRY_VERSION_VARIABLE = "xpack.stack.monitoring.template.release.version";
8282
private static final String STACK_TEMPLATE_VERSION = "8";
8383
private static final String STACK_TEMPLATE_VERSION_VARIABLE = "xpack.stack.monitoring.template.version";

0 commit comments

Comments
 (0)