use of com.metamx.emitter.core.LoggingEmitter in project druid by druid-io.
the class LookupCoordinatorManagerTest method setUpStatic.
@BeforeClass
public static void setUpStatic() {
LoggingEmitter loggingEmitter = EasyMock.createNiceMock(LoggingEmitter.class);
EasyMock.replay(loggingEmitter);
SERVICE_EMITTER = new ServiceEmitter("", "", loggingEmitter) {
@Override
public void emit(Event event) {
EVENT_EMITS.incrementAndGet();
super.emit(event);
}
};
com.metamx.emitter.EmittingLogger.registerEmitter(SERVICE_EMITTER);
}
use of com.metamx.emitter.core.LoggingEmitter in project druid by druid-io.
the class KafkaIndexTaskTest method setUp.
@Before
public void setUp() throws Exception {
emitter = new ServiceEmitter("service", "host", new LoggingEmitter(log, LoggingEmitter.Level.ERROR, new DefaultObjectMapper()));
emitter.start();
EmittingLogger.registerEmitter(emitter);
makeToolboxFactory();
zkServer = new TestingCluster(1);
zkServer.start();
kafkaServer = new TestBroker(zkServer.getConnectString(), tempFolder.newFolder(), 1, ImmutableMap.of("num.partitions", "2"));
kafkaServer.start();
taskExec = MoreExecutors.listeningDecorator(Executors.newCachedThreadPool(Execs.makeThreadFactory("kafka-task-test-%d")));
handoffConditionTimeout = 0;
reportParseExceptions = false;
doHandoff = true;
}
Aggregations