public void stopStatsd() {
   if (statsdMockServer != null) {
     statsdMockServer.after();
   }
 }
 public void startStatsd() throws Throwable {
   statsdMockServer = new StatsdMockServer();
   statsdMockServer.before();
   System.setProperty("statsd.host", "localhost");
   System.setProperty("statsd.port", Integer.toString(statsdMockServer.getPort()));
 }