-
Notifications
You must be signed in to change notification settings - Fork 0
/
telegraf.conf
134 lines (126 loc) · 5.67 KB
/
telegraf.conf
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
[global_tags]
# the env tag is used by the application for multi-environments management
env = "Dev"
# the label tag is an optional tag used by the application that you can use as additional label for the services or infrastructure
label = "sample-application"
[agent]
interval = "10s"
flush_interval = "10s"
## Logging configuration:
## Run telegraf with debug log messages.
debug = true
## Run telegraf in quiet mode (error log messages only).
quiet = false
## Specify the log file name. The empty string means to log to stderr.
logfile = ""
# outputs
[[outputs.http]]
url = "https://splunk:8088/services/collector"
timeout = "15s"
insecure_skip_verify = true
data_format = "splunkmetric"
## Provides time, index, source overrides for the HEC
splunkmetric_hec_routing = true
## Additional HTTP headers
[outputs.http.headers]
# Should be set manually to "application/json" for json data_format
Content-Type = "application/json"
Authorization = "Splunk splunk_telegraf_hec_token" # <-- Ask your Splunk administrator dor a valid token
X-Splunk-Request-Channel = "splunk_telegraf_hec_token"
[[inputs.cpu]]
[[inputs.disk]]
[[inputs.diskio]]
[[inputs.jolokia2_agent]]
urls = ["http://sample-application:8778/jolokia/"] # <-- Url of your jolokia agent
# Kafka JVM monitoring
[[inputs.jolokia2_agent.metric]]
name = "java_lang_memory"
mbean = "java.lang:type=Memory"
[[inputs.jolokia2_agent.metric]]
name = "java_lang_memory_pool"
mbean = "java.lang:type=MemoryPool,name=*"
paths = ["Usage"]
tag_keys = ["name"]
[[inputs.jolokia2_agent.metric]]
name = "java_lang_threading"
mbean = "java.lang:type=Threading"
paths = ["ThreadCount","PeakThreadCount","DaemonThreadCount"]
[[inputs.jolokia2_agent.metric]]
name = "java_lang_garbage_collector"
mbean = "java.lang:type=GarbageCollector,name=*"
paths = ["CollectionCount","CollectionTime"]
tag_keys = ["name"]
## Producer
[[inputs.jolokia2_agent.metric]]
name = "kafka_producer_app_info"
mbean = "kafka.producer:type=app-info,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_producer_producer_metrics"
mbean = "kafka.producer:type=producer-metrics,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_producer_producer_node_metrics"
mbean = "kafka.producer:type=producer-node-metrics,client-id=*,node-id=*"
tag_keys = ["client-id", "node-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_producer_producer_topic_metrics"
mbean = "kafka.producer:type=producer-topic-metrics,client-id=*,topic=*"
tag_keys = ["client-id", "topic"]
## Streams
[[inputs.jolokia2_agent.metric]]
name = "stream_metrics"
mbean = "kafka.streams:type=stream-metrics,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "stream_processor_node_metrics"
mbean = "kafka.streams:type=stream-processor-node-metrics,client-id=*,task-id=*,processor-node-id=*"
tag_keys = ["client-id","task-id","processor-node-id"]
[[inputs.jolokia2_agent.metric]]
name = "stream_record_cache_metrics"
mbean = "kafka.streams:type=stream-record-cache-metrics,client-id=*,task-id=*,record-cache-id=*"
tag_keys = ["client-id","task-id","record-cache-id"]
[[inputs.jolokia2_agent.metric]]
name = "stream_rocksdb_state_metrics"
mbean = "kafka.streams:type=stream-rocksdb-state-metrics,client-id=*,task-id=*,rocksdb-state-id=*"
tag_keys = ["client-id","task-id","rocksdb-state-id"]
[[inputs.jolokia2_agent.metric]]
name = "stream_rocksdb_window_metrics"
mbean = "kafka.streams:type=stream-rocksdb-window-metrics,client-id=*,rocksdb-window-id=*,task-id=*"
tag_keys = ["client-id","task-id","rocksdb-window-id"]
[[inputs.jolokia2_agent.metric]]
name = "stream_task_metrics"
mbean = "kafka.streams:type=stream-task-metrics,client-id=*,task-id=*"
tag_keys = ["client-id","task-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_metrics_count"
mbean = "kafka.streams:type=kafka-metrics-count"
## Consumer
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_app_info"
mbean = "kafka.consumer:type=app-info,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_consumer_fetch_manager_metrics"
mbean = "kafka.consumer:type=consumer-fetch-manager-metrics,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_consumer_fetch_manager_metrics"
mbean = "kafka.consumer:type=consumer-fetch-manager-metrics,client-id=*,topic=*"
tag_keys = ["client-id", "topic"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_consumer_fetch_manager_metrics"
mbean = "kafka.consumer:type=consumer-fetch-manager-metrics,client-id=*,topic=*,partition=*"
tag_keys = ["client-id", "topic", "partition"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_consumer_coordinator_metrics"
mbean = "kafka.consumer:type=consumer-coordinator-metrics,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_consumer_metrics"
mbean = "kafka.consumer:type=consumer-metrics,client-id=*"
tag_keys = ["client-id"]
[[inputs.jolokia2_agent.metric]]
name = "kafka_consumer_consumer_node_metrics"
mbean = "kafka.consumer:type=consumer-node-metrics,client-id=*,node-id=*"
tag_keys = ["client-id", "node-id"]