metrology/reporter/statsd.py
def format_metric_string(self, name, value, m_type):
        """Compose a statsd compatible string for a metric's measurement."""

        # NOTE(romcheg): This serialized metric template is based on
        #                statsd's documentation.
        template = '{name}:{value}|{m_type}\n'

        if self.prefix:
            name = "{prefix}.{m_name}".format(prefix=self.prefix, m_name=name)

        return template.format(name=name, value=value, m_type=m_type)
def format_metric_string(self, name, value, m_type):
        # NOTE(romcheg): This serialized metric template is based on
        #                statsd's documentation.
        template = '{name}:{value}|{m_type}\n'

        if self.prefix:
            name = "{prefix}.{m_name}".format(prefix=self.prefix, m_name=name)

        return template.format(name=name, value=value, m_type=m_type)
def format_metric_string ( self , name , value , m_type ) : # NOTE(romcheg): This serialized metric template is based on #                statsd's documentation. template = '{name}:{value}|{m_type}\n' if self . prefix : name = "{prefix}.{m_name}" . format ( prefix = self . prefix , m_name = name ) return template . format ( name = name , value = value , m_type = m_type )
Compose a statsd compatible string for a metric's measurement.
Compose a statsd compatible string for a metric s measurement .