private void addStaticFieldToAppender() throws JoranException {
LoggerContext lc = (LoggerContext) LoggerFactory.getILoggerFactory();
JoranConfigurator joranConfigurator = new JoranConfigurator();
joranConfigurator.setContext(lc);
joranConfigurator.doConfigure(Resources.getResource("staticAdditionalFields.xml"));
}
private ImmutableMap<String, Object> addField(ImmutableMap<String, Object> map, String key, String value) {
return ImmutableMap.<String, Object>builder().putAll(map).put(key,
value).build();