def _metric_to_riemann_event(self, metric):
        """
        Convert a metric to a dictionary representing a Riemann event.
        """
        # Riemann has a separate "host" field, so remove from the path.
        path = '%s.%s.%s' % (
            metric.getPathPrefix(),
            metric.getCollectorPath(),
            metric.getMetricPath()
        )

        return self.client.create_event({
            'host': metric.host,
            'service': path,
            'time': metric.timestamp,
            'metric_f': float(metric.value),
            'ttl': metric.ttl,
        })

        Convert a metric to a dictionary representing a Riemann event.
        
src/diamond/handler/riemann.py