Times given function and log metric in ms for duration of execution.

        >>> import time
        >>> client = StatsdClient()
        >>> client.timeit("latency", time.sleep, 0.5)

def timeit(self, metric, func, *args, **kwargs):
        """
        Times given function and log metric in ms for duration of execution.

        >>> import time
        >>> client = StatsdClient()
        >>> client.timeit("latency", time.sleep, 0.5)
        """
        (res, seconds) = timeit(func, *args, **kwargs)
        self.timing(metric, seconds * 1000.0)
        return res