Welcome! Log In Create A New Profile

Advanced

Re: why delta only include the execution time of ngx_process_events not ngx_event_process_posted (Zhang Chao)

Valentin V. Bartenev
October 31, 2017 10:14AM
On Sunday 29 October 2017 21:35:15 yang chen wrote:
> Thanks for your reply, why calling the ngx_event_expire_timers is
> unnecessary when ngx_process_events handler returns so quickly that the
> millisecond precision is not enough to display the calling time(less than
> 1ms maybe).
>
> ngx_process_events handler returns quickly which doesn't
> mean ngx_event_process_posted return quickly, maybe it excute for 2 ms or
> more


First of all, ngx_process_events() is the function that actually _waits_
and updates process time. So, there's no sense to move the calculation
of delta elsewhere, since ngx_current_msec will be the same anyway.

In most cases the time is spend by waiting on kernel for events, not by
processing the events and executing handlers.

Normally ngx_event_process_posted should not spend 2ms, otherwise that
would result in less than 500 rps, which can only indicate blocking issue
or overload.

wbr, Valentin V. Bartenev

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

RE: Re: why delta only include the execution time of ngx_process_events not ngx_event_process_posted (Zhang Chao)

yang chen October 29, 2017 09:36AM

Re: why delta only include the execution time of ngx_process_events not ngx_event_process_posted (Zhang Chao)

Valentin V. Bartenev October 31, 2017 10:14AM

higher precision timings [ Re: why delta only include the execution time of ngx_process_events not ngx_event_process_posted (Zhang Chao)

pbooth October 31, 2017 01:26PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 117
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