0

I need to only add the logger which logs all the api requests coming to my server. In the documentation,

django.request

Log messages related to the handling of requests. 5XX responses are raised as ERROR messages; 4XX responses are raised as WARNING messages. Requests that are logged to the django.security logger aren’t logged to django.request.

django.server

Log messages related to the handling of requests received by the server invoked by the runserver command. HTTP 5XX responses are logged as ERROR messages, 4XX responses are logged as WARNING messages, and everything else is logged as INFO.

I tried disabling django.server but I could not see any difference in my logs. So, I thought maybe it is for requests emanating from my server. Nope. Still nothing.

So what does django.server do?

anantdd
  • 125
  • 7

1 Answers1

0

I had a similar problem and got clarification from Django guys - configuration in settings.pay is only for the dev server invoked by run server command. Otherwise you need to call logger in the code. See this ticket https://code.djangoproject.com/ticket/34236#comment:4

Derek M
  • 1
  • 2