Jetty: how to disable logging?

前端 未结 7 1877
隐瞒了意图╮
隐瞒了意图╮ 2020-12-30 02:35

I am trying to embed Jetty 6.1 in another program. Jetty is dumping INFO-log information and I need to turn it off. Is there a simple way to disable logging programmaticaly?

相关标签:
7条回答
  • 2020-12-30 03:10

    Set the StdErrLog level to WARN, before starting your server:

    Properties p = new Properties();
    p.setProperty("org.eclipse.jetty.LEVEL", "WARN");
    org.eclipse.jetty.util.log.StdErrLog.setProperties(p);
    
    0 讨论(0)
提交回复
热议问题