admin管理员组文章数量:1026343
I am using Django to serve an application, and I noticed some slowing down recently.
So I went and checked the console that serves the server, that usually logs lines of this format :
<date_time> "GET <path> HTTP/1.1" <HTTP_STATUS> <response_time>
What I thought was the response time in milliseconds is apparently not, as I get values that would be ludicrous (example 3923437 for a query that when timed in python directly takes 0.936 seconds). I'm pretty sure it's a response time though, as it's always scaled with the time I wait.
Can someone explain to me what that number is ? I couldn't find where this default log is documented.
I am using Django to serve an application, and I noticed some slowing down recently.
So I went and checked the console that serves the server, that usually logs lines of this format :
<date_time> "GET <path> HTTP/1.1" <HTTP_STATUS> <response_time>
What I thought was the response time in milliseconds is apparently not, as I get values that would be ludicrous (example 3923437 for a query that when timed in python directly takes 0.936 seconds). I'm pretty sure it's a response time though, as it's always scaled with the time I wait.
Can someone explain to me what that number is ? I couldn't find where this default log is documented.
Share Improve this question edited Nov 18, 2024 at 14:53 Equino asked Nov 18, 2024 at 10:09 EquinoEquino 816 bronze badges 2- i think the natural candidate would be content-length – folen gateis Commented Nov 18, 2024 at 10:35
- Oh my, what a misunderstanding, I guess it "scaled" with the response time because it concerned more data and thus spent longer on the database query. – Equino Commented Nov 18, 2024 at 14:53
1 Answer
Reset to default 3It's the response size and it's printed by Python http-server which Django inherits. That explains why it's not documented by Django, because it's not the Django code that prints it.
You can verify that by looking at this Django module. This is the line that starts the http-server.
It inherits from Python http-server. This is the line that prints the response size.
I am using Django to serve an application, and I noticed some slowing down recently.
So I went and checked the console that serves the server, that usually logs lines of this format :
<date_time> "GET <path> HTTP/1.1" <HTTP_STATUS> <response_time>
What I thought was the response time in milliseconds is apparently not, as I get values that would be ludicrous (example 3923437 for a query that when timed in python directly takes 0.936 seconds). I'm pretty sure it's a response time though, as it's always scaled with the time I wait.
Can someone explain to me what that number is ? I couldn't find where this default log is documented.
I am using Django to serve an application, and I noticed some slowing down recently.
So I went and checked the console that serves the server, that usually logs lines of this format :
<date_time> "GET <path> HTTP/1.1" <HTTP_STATUS> <response_time>
What I thought was the response time in milliseconds is apparently not, as I get values that would be ludicrous (example 3923437 for a query that when timed in python directly takes 0.936 seconds). I'm pretty sure it's a response time though, as it's always scaled with the time I wait.
Can someone explain to me what that number is ? I couldn't find where this default log is documented.
Share Improve this question edited Nov 18, 2024 at 14:53 Equino asked Nov 18, 2024 at 10:09 EquinoEquino 816 bronze badges 2- i think the natural candidate would be content-length – folen gateis Commented Nov 18, 2024 at 10:35
- Oh my, what a misunderstanding, I guess it "scaled" with the response time because it concerned more data and thus spent longer on the database query. – Equino Commented Nov 18, 2024 at 14:53
1 Answer
Reset to default 3It's the response size and it's printed by Python http-server which Django inherits. That explains why it's not documented by Django, because it's not the Django code that prints it.
You can verify that by looking at this Django module. This is the line that starts the http-server.
It inherits from Python http-server. This is the line that prints the response size.
本文标签: pythonWhat is the number at the end of the Django GET logStack Overflow
版权声明:本文标题:python - What is the number at the end of the Django GET log? - Stack Overflow 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://it.en369.cn/questions/1745627555a2159956.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论