At php-fpm.org:
fastcgi_finish_request () is a php function that stops response output. The web server immediately begins to transmit the response “slowly and sadly” to the client, and php at the same time can do a lot of useful things in the context of the request, such as saving a session, converting downloaded videos, processing all kinds of statistics, etc.
I have not used fastcgi_finish_request() myself, but if time is up, the server should send back the response received so far, it is considered the "runtime" for this method in the PHP script; it seems pretty clear why this function "consumes" so much time, because it depends on your network connection to the server and client (for example, ping).
Does runtime change when using the local development environment?
source share