File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed
Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -158,7 +158,7 @@ def read_callback():
158158 return
159159
160160 for key ,value in info .items ():
161- key_prefix = None
161+ key_prefix = ''
162162 key_root = key
163163 if not value in METRIC_TYPES :
164164 try :
@@ -169,12 +169,9 @@ def read_callback():
169169 continue
170170
171171 key_root , val_type = METRIC_TYPES [key_root ]
172- if key_prefix :
173- key_name = METRIC_DELIM .join ([key_prefix , key_root ])
174- else :
175- key_name = key_root
176172 val = collectd .Values (plugin = NAME , type = val_type )
177- val .type_instance = key_name
173+ val .plugin_instance = key_prefix
174+ val .type_instance = key_root
178175 val .values = [ value ]
179176 val .dispatch ()
180177
@@ -190,4 +187,4 @@ def logger(t, msg):
190187 collectd .notice ('%s: %s' % (NAME , msg ))
191188
192189collectd .register_config (configure_callback )
193- collectd .register_read (read_callback )
190+ collectd .register_read (read_callback )
You can’t perform that action at this time.
0 commit comments