Understanding Nginx Logging: Does $request_time include Django backend response time?
I am checking the performance and response times of a web-app and the parties involved in it. I have a question regarding the logging that nginx makes of api rest requests to the backend of the web-app (React-Django).
Nginx has the ability to log the $request_time to /var/log/nginx/access.log when serving a request from the backend. The question is: does it contain within that time in seconds the time that the Django backend takes to respond to the request? This is not clear to me from reading the documentation Nginx log_format.
In what I tested, django responds to a request in 30 ms and Nginx logs that request as served in 33 ms. Do those 33 ms contain the 30 ms that django takes or are they separate? or are they only referring to the handling that Nginx can do (i.e. manage the request in a queue if there is a lot of service demand)?
Thanks in advance!
Read more here: Source link