def stop(self, bucket_key=b'total'):
        """Stops the timer and sends total time to statsd.
        """
        bucket_key = bucket_key if isinstance(bucket_key, bytes) else bucket_key.encode('utf8')
        self._stop = time.time() * 1000
        self._client.timing(self._bucket + b'.' + bucket_key,
                            self._stop - self._start)
dataset/ETHPy150Open gaelenh/python-statsd-client/statsd.py/StatsdTimer.stop/original