Welcome! Log In Create A New Profile

Advanced

Re: most of value of $request_time is 0.000

Maxim Dounin
March 25, 2015 04:02PM
Hello!

On Wed, Mar 25, 2015 at 11:55:14AM +0800, baipeng wrote:

> Our version of nginx is nginx/1.0.8 and we have write a third
> party module to handle the http request. Because the process
> model of our third party module is synchronous so the nginx
> worker process will be blocked until one request accomplished.
> The average time cost of one request is about 50ms.But After we
> set $request_time in nginx.conf, the most of the value of
> $request_time is 0.000.Even we set timer_resolution 1ms in
> nginx.conf most of value of $request_time is still 0.000.
> Are there anyone can tell me why it occured?

Time as seen by nginx is only updated once per event loop
iteration, so if you block processing for a while and then
finalize the request - this time won't be visible in
$request_time.

The timer_resolution may change things on some platforms, but it's
not designed to do so. Instead, it's to _reduce_ timer resolution
compared to what nginx does by default, see
http://nginx.org/r/timer_resolution.

--
Maxim Dounin
http://nginx.org/

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

most of value of $request_time is 0.000

baipeng March 24, 2015 11:56PM

Re: most of value of $request_time is 0.000

Maxim Dounin March 25, 2015 04:02PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 310
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready