forked from markkimsal/statsd-elasticsearch-backend
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathes-index-template.sh
88 lines (88 loc) · 2.51 KB
/
es-index-template.sh
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
curl -XPUT -H 'Content-Type: application/json' "${ES_HOST:-localhost}:${ES_PORT:-9200}/_template/statsd-template" -d '
{
"template" : "statsd-*",
"settings" : {
"number_of_shards" : 1
},
"mappings" : {
"stats" : {
"_source" : { "enabled" : true },
"properties": {
"type": {
"type": "keyword"
},
"@timestamp": {
"type": "date"
},
"val": {
"type": "double",
"index": "true"
},
"name": {
"type": "keyword",
"index": "true"
},
"count_ps": {
"type": "float",
"index": "true"
},
"count": {
"type": "float",
"index": "true"
},
"upper": {
"type": "float",
"index": "true"
},
"lower": {
"type": "float",
"index": "true"
},
"mean": {
"type": "float",
"index": "true"
},
"median": {
"type": "float",
"index": "true"
},
"std": {
"type": "float",
"index": "true"
},
"sum": {
"type": "float",
"index": "true"
},
"mean_90": {
"type": "float",
"index": "true"
},
"upper_90": {
"type": "float",
"index": "true"
},
"sum_90": {
"type": "float",
"index": "true"
},
"bin_100": {
"type": "integer",
"index": "true"
},
"bin_500": {
"type": "integer",
"index": "true"
},
"bin_1000": {
"type": "integer",
"index": "true"
},
"bin_inf": {
"type": "integer",
"index": "true"
}
}
}
}
}'