コード例 #1
0
 public static void enable(Config config) {
   try {
     final RiemannReporter reporter = new RiemannReporter(config);
     reporter.start(config.period, config.unit);
   } catch (Exception e) {
     LOG.error("Error creating/starting Riemann reporter: ", e);
   }
 }
コード例 #2
0
  public static void enable(final Config config) {
    try {
      if (config == null) throw new IllegalArgumentException("Config cannot be null");

      final RiemannReporter reporter = new RiemannReporter(config);
      reporter.start(config.period, config.unit);
    } catch (Exception e) {
      LOG.error("Error creating/starting Riemann reporter: ", e);
    }
  }