protected void doInit(TwillContext context) {
try {
getCConfiguration().set(Constants.MetricsProcessor.ADDRESS, context.getHost().getCanonicalHostName());
Injector injector = createGuiceInjector(getCConfiguration(), getConfiguration());
injector.getInstance(LogAppenderInitializer.class).initialize();
LoggingContextAccessor.setLoggingContext(new ServiceLoggingContext(Constants.Logging.SYSTEM_NAME,
Constants.Logging.COMPONENT_NAME,
Constants.Service.METRICS_PROCESSOR));
LOG.info("Initializing runnable {}", name);
// Set the hostname of the machine so that cConf can be used to start internal services