Bug 60508

Summary: AccessLogValve using %D doesn't log milliseconds for HTTP/2
Product: Tomcat 8 Reporter: Kenny Colliander Nordin <kecon81>
Component: ConnectorsAssignee: Tomcat Developers Mailing List <dev>
Severity: normal    
Priority: P2    
Version: 8.5.8   
Target Milestone: ----   
Hardware: PC   
OS: Linux   

Description Kenny Colliander Nordin 2016-12-22 09:39:22 UTC
The last parameter %D in my example should output "Time taken to process the request, in millis".

server.xml configuration in a Host element:

<Valve className="org.apache.catalina.valves.AccessLogValve" prefix="access-" suffix=".log" pattern="%h %l %u %t '%r' %s %b %D" />

Log output for HTTP/2 requests:
85.x.y.z - - [22/Dec/2016:09:51:49 +0100] 'GET / HTTP/2.0' 200 1165 1482396709364

Using connector org.apache.coyote.http11.Http11AprProtocol with upgrade protocol org.apache.coyote.http2.Http2Protocol

The value seems to be the UNIX timestamp instead for HTTP/2.0. HTTP/1.1 requests works as expected.
Comment 1 Remy Maucherat 2017-01-02 15:46:38 UTC
Fixed for 9M16 and 8.5.10.