Class AccessLogAdapter

  • All Implemented Interfaces:
    AccessLog

    public class AccessLogAdapter
    extends java.lang.Object
    implements AccessLog
    A helper class that wraps several AccessLog instances.
    • Constructor Detail

      • AccessLogAdapter

        public AccessLogAdapter​(AccessLog log)
    • Method Detail

      • log

        public void log​(Request request,
                        Response response,
                        long time)
        Description copied from interface: AccessLog
        Add the request/response to the access log using the specified processing time.
        Specified by:
        log in interface AccessLog
        Parameters:
        request - Request (associated with the response) to log
        response - Response (associated with the request) to log
        time - Time taken to process the request/response in milliseconds (use 0 if not known)
      • setRequestAttributesEnabled

        public void setRequestAttributesEnabled​(boolean requestAttributesEnabled)
        Description copied from interface: AccessLog
        Should this valve set request attributes for IP address, hostname, protocol and port used for the request? This are typically used in conjunction with the AccessLogValve which will otherwise log the original values. The attributes set are:
        • org.apache.catalina.RemoteAddr
        • org.apache.catalina.RemoteHost
        • org.apache.catalina.Protocol
        • org.apache.catalina.ServerPost
        Specified by:
        setRequestAttributesEnabled in interface AccessLog
        Parameters:
        requestAttributesEnabled - true causes the attributes to be set, false disables the setting of the attributes.