RollbarAppender extends AbstractAppender { @Override public void append(LogEvent event) { if (event.getLoggerName() != null && event.getLoggerName().startsWith(PACKAGE_NAME)) { LOGGER.warn("Recursive logging from [{}] for appender [{}].", event.getLoggerName(), getName()); return; } ThrowableProxy throwableProxy = event.getThrownProxy(); ThrowableWrapper rollbarThrowableWrapper = buildRollbarThrowableWrapper(throwableProxy); Map<String, Object> custom = this.buildCustom(event); String message = event.getMessage() != null ? event.getMessage().getFormattedMessage() : null; Level level = this.getLevel(event); rollbar.log(rollbarThrowableWrapper, custom, message, level, false); } protected  RollbarAppender(String name, Filter filter, Layout<? extends Serializable> layout,
      boolean ignoreExceptions, Rollbar rollbar); @PluginFactory static RollbarAppender createAppender(
      @PluginAttribute("accessToken") @Required final String accessToken,
      @PluginAttribute("codeVersion") final String codeVersion,
      @PluginAttribute("endpoint") final String endpoint,
      @PluginAttribute("environment") final String environment,
      @PluginAttribute("language") final String language,
      @PluginAttribute("enabled") final boolean enabled,
      @PluginAttribute("configProviderClassName") final String configProviderClassName,
      @PluginAttribute("name") @Required final String name,
      @PluginElement("Layout") Layout<? extends Serializable> layout,
      @PluginElement("Filter") Filter filter,
      @PluginAttribute("ignoreExceptions") final String ignore
  ); @Override void append(LogEvent event); @Override boolean stop(final long timeout, final TimeUnit timeUnit); @Override void stop();  }
@Test public void shouldNotLogIfLoggerIsRollbar() { when(event.getLoggerName()).thenReturn("com.rollbar.any"); sut.append(event); verify(rollbar, never()).log(any(ThrowableWrapper.class), ArgumentMatchers.<String, Object>anyMap(), anyString(), any(Level.class), anyBoolean()); }