class_docstr: This class encapsulates a metric's name, logical group and its
  related attributes (tags).
  
  group, tags parameters can be used to create unique metric names.
  e.g. domainName:type=group,key1=val1,key2=val2
  
  Usage looks something like this:
  
      # set up metrics:
      metric_tags = {'client-id': 'producer-1', 'topic': 'topic'}
      metric_config = MetricConfig(tags=metric_tags)
  
      # metrics is the global repository of metrics and sensors
      metrics = Metrics(metric_config)
  
      sensor = metrics.sensor('message-sizes')
      metric_name = metrics.metric_name('message-size-avg',
                                        'producer-metrics',
                                        'average message size')
      sensor.add(metric_name, Avg())
  
      metric_name = metrics.metric_name('message-size-max',
      sensor.add(metric_name, Max())
  
      tags = {'client-id': 'my-client', 'topic': 'my-topic'}
      metric_name = metrics.metric_name('message-size-min',
                                        'producer-metrics',
                                        'message minimum size', tags)
      sensor.add(metric_name, Min())
  
      # as messages are sent we record the sizes
      sensor.record(message_size)
class_docstr_tok: ["This","class","encapsulates","a","metric","'s","name",",","logical","group","and","its","related","attributes","(","tags",")",".","group",",","tags","parameters","can","be","used","to","create","unique","metric","names",".","e.g",".","domainName",":","type=group",",","key1=val1",",","key2=val2","Usage","looks","something","like","this",":","#","set","up","metrics",":","metric_tags","=","{","'client-id","'",":","'producer-1","'",",","'topic","'",":","'topic","'","}","metric_config","=","MetricConfig","(","tags=metric_tags",")","#","metrics","is","the","global","repository","of","metrics","and","sensors","metrics","=","Metrics","(","metric_config",")","sensor","=","metrics.sensor","(","'message-sizes","'",")","metric_name","=","metrics.metric_name","(","'message-size-avg","'",",","'producer-metrics","'",",","'average","message","size","'",")","sensor.add","(","metric_name",",","Avg","(",")",")","metric_name","=","metrics.metric_name","(","'message-size-max","'",",","sensor.add","(","metric_name",",","Max","(",")",")","tags","=","{","'client-id","'",":","'my-client","'",",","'topic","'",":","'my-topic","'","}","metric_name","=","metrics.metric_name","(","'message-size-min","'",",","'producer-metrics","'",",","'message","minimum","size","'",",","tags",")","sensor.add","(","metric_name",",","Min","(",")",")","#","as","messages","are","sent","we","record","the","sizes","sensor.record","(","message_size",")"]
code: def group(self):
      return self._group
  
file_path: kafka-python/kafka/metrics/metric_name.py
imports: from __future__ import absolute_import
  import copy
label_desc: Use image node_id 3 for calling the MetricName obj's underlying member method code with example usage: obj.group() and returns: self