예제 #1
0
  public void configure() throws InterruptedException {

    sa.setSyslogHost("localhost");
    sa.setFacility("AUTH");
    sa.setPort(10514);
    sa.setSuffixPattern("%-5level [%logger:%line] [%thread] %msg %ex{short}%n");
    sa.start();
    assertTrue(sa.isStarted());

    String loggerName = this.getClass().getName();
    Logger logger = lc.getLogger(loggerName);
    logger.addAppender(sa);
  }
예제 #2
0
 @Before
 public void setUp() throws Exception {
   lc.setName("test");
   sa.setContext(lc);
 }