Request_time > upstream_response_time ,difference between 2 seconds sometimes, same most of the time

kong :0.14.1

$request_time>$upstream_response_time ,difference between 2 seconds sometimes, same most of the time,return data is small (19k)

$request_time: request processing time in seconds with a milliseconds resolution; time elapsed between the first bytes were read from the client and the log write after the last bytes were sent to the client。

$upstream_response_time : keeps time spent on receiving the response from the upstream server; the time is kept in seconds with millisecond resolution.

Sorry, what is the question here?

It is expected that the request time is >= upstream_response_time.

request_time = upstream_response_time + kong_processing_time(via plugins)

nginx log:
log_format json ‘{“dt”:"$time_iso8601",“ra”:"$remote_addr",“ip”:"$http_x_forwarded_for",“c”:"$status",“m”:"$request_method",“up”:"$upstream_addr",“rt”:"$request_time",“urt”:"$upstream_response_time",“h”:"$http_host",“qs”:"$query_string",“uri”:"$uri",“rs”:"$body_bytes_sent",“ref”:"$http_referer",“ua”:"$http_user_agent",“ssl”:"$ssl_protocol"}’;

$equest_time > $upstream_response_time


© 2018 Kong Inc.    Terms  •  Privacy  •  FAQ