javax.servlet.SingleThreadModel#org.apache.tomcat.util.log.SystemLogHandler源码实例Demo

下面列出了javax.servlet.SingleThreadModel#org.apache.tomcat.util.log.SystemLogHandler 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。

private void initFilter() throws ServletException {
    if (context instanceof StandardContext &&
            context.getSwallowOutput()) {
        try {
            SystemLogHandler.startCapture();
            filter.init(this);
        } finally {
            String capturedlog = SystemLogHandler.stopCapture();
            if (capturedlog != null && capturedlog.length() > 0) {
                getServletContext().log(capturedlog);
            }
        }
    } else {
        filter.init(this);
    }

    // Expose filter via JMX
    registerJMX();
}
 
源代码2 项目: Tomcat7.0.67   文件: ApplicationFilterConfig.java
private void initFilter() throws ServletException {
    if (context instanceof StandardContext &&
            context.getSwallowOutput()) {
        try {
            SystemLogHandler.startCapture();
            filter.init(this);
        } finally {
            String capturedlog = SystemLogHandler.stopCapture();
            if (capturedlog != null && capturedlog.length() > 0) {
                getServletContext().log(capturedlog);
            }
        }
    } else {
        filter.init(this);
    }
    
    // Expose filter via JMX
    registerJMX();
}
 
源代码3 项目: tomcatsrc   文件: ApplicationFilterConfig.java
private void initFilter() throws ServletException {
    if (context instanceof StandardContext &&
            context.getSwallowOutput()) {
        try {
            SystemLogHandler.startCapture();
            filter.init(this);
        } finally {
            String capturedlog = SystemLogHandler.stopCapture();
            if (capturedlog != null && capturedlog.length() > 0) {
                getServletContext().log(capturedlog);
            }
        }
    } else {
        filter.init(this);
    }
    
    // Expose filter via JMX
    registerJMX();
}
 
源代码4 项目: Tomcat7.0.67   文件: Embedded.java
protected void initStreams() {
    if (redirectStreams) {
        // Replace System.out and System.err with a custom PrintStream
        System.setOut(new SystemLogHandler(System.out));
        System.setErr(new SystemLogHandler(System.err));
    }
}
 
源代码5 项目: tomcatsrc   文件: Embedded.java
protected void initStreams() {
    if (redirectStreams) {
        // Replace System.out and System.err with a custom PrintStream
        System.setOut(new SystemLogHandler(System.out));
        System.setErr(new SystemLogHandler(System.err));
    }
}
 
源代码6 项目: Tomcat8-Source-Read   文件: Catalina.java
protected void initStreams() {
    // Replace System.out and System.err with a custom PrintStream
    System.setOut(new SystemLogHandler(System.out));
    System.setErr(new SystemLogHandler(System.err));
}
 
源代码7 项目: Tomcat7.0.67   文件: Catalina.java
protected void initStreams() {
    // Replace System.out and System.err with a custom PrintStream
    System.setOut(new SystemLogHandler(System.out));
    System.setErr(new SystemLogHandler(System.err));
}
 
源代码8 项目: tomcatsrc   文件: Catalina.java
protected void initStreams() {
    // Replace System.out and System.err with a custom PrintStream
    System.setOut(new SystemLogHandler(System.out));
    System.setErr(new SystemLogHandler(System.err));
}