@@ -174,9 +174,16 @@ Full Configuration Example
174
174
# See https://github.com/influxdata/influxdb/tree/master/services/graphite for template
175
175
# configuration documentation
176
176
#
177
- # Note that no special compensation is given to the `field` key if it is used in
178
- # template configuration and templates with `field` in them should be considered
179
- # as not fully supported as of yet.
177
+ # Note that care should be taken so that template configuration results in
178
+ # sane measurement and field names that do not override each other and so
179
+ # that wildcard queries do not have conflicting tags and can be
180
+ # satisfied in **one query** by InfluxDB
181
+ #
182
+ # For best InfluxDB performance and so that data can be queried correctly
183
+ # by InfluxGraph, fewer measurements with multiple fields are preferred.
184
+ #
185
+ # NB - separator for templates is not configurable as of yet
186
+ #
180
187
templates:
181
188
#
182
189
# Template format: [filter] <template> [tag1=value1,tag2=value2]
@@ -187,20 +194,29 @@ Full Configuration Example
187
194
# filter on metrics starting with `environment`,
188
195
# use tags `environment`, `host` and `resource` with measurement name `cpu0.load` and
189
196
# extra static tags `region` and `agent`
190
- - environment.* environment.host.resource.measurement* region=us-east1,agent=sensu
197
+ - production.* environment.host.resource.measurement* region=us-east1,agent=sensu
198
+
191
199
#
192
200
## Template only
193
201
# The following template does not use filter or extra tags.
194
202
# For a metric path `my_host.cpu.cpu0.load` it will use tags `host` and `resource`
195
203
# with measurement name `cpu0.load`
196
204
- host.resource.measurement*
205
+
197
206
#
198
207
## Drop prefix, template with tags after measurement
199
208
# For a metric path `stats.load.my_host.cpu` the following template will use tags
200
209
# `host` and `resource` and remove `stats` prefix from metric paths
201
210
- stats.* ..measurement.host.resource
202
211
203
- # A catch-all template of `measurement*` _should not_ be used -
212
+ #
213
+ ## Measurement with multiple fields
214
+ # For metric paths `my_host.cpu-0.cpu-idle`, `my_host.cpu-0.cpu-user` et al, the
215
+ # following template will use tags `host` with measurement name `cpu-0` and fields
216
+ # `cpu-idle`, `cpu-user` et al
217
+ - host.measurement.field*
218
+
219
+ # NB - A catch-all template of `measurement*` _should not_ be used -
204
220
# that is the default and would have the same effect as if no template was provided
205
221
#
206
222
## Examples from InfluxDB Graphite service configuration
@@ -212,7 +228,7 @@ Full Configuration Example
212
228
# - stats.* .host.measurement* region=us-west,agent=sensu
213
229
214
230
# filter + template with field key
215
- # - stats.* .host.measurement.field
231
+ # - stats.* .host.measurement.field*
216
232
217
233
## (Optional) Memcache integration
218
234
#
0 commit comments