use of com.codingchili.core.metrics.MetricCollector in project chili-core by codingchili.
the class SystemContext method initialize.
private void initialize() {
this.logger = new RemoteLogger(this, SystemContext.class);
// add a shutdown hook for gracefully shutting down the context.
ShutdownHook.register(this);
vertx.exceptionHandler(throwable -> logger.onError(throwable));
if (!initialized.get()) {
this.metrics = new MetricCollector(this, Configurations.system().getMetrics(), MetricSettings.REGISTRY_NAME);
StartupListener.publish(this);
initialized.set(true);
}
}
Aggregations