On Mon, Feb 3, 2014 at 8:20 PM, Chris Wilson <[email protected]> wrote:

> Hi all,
>
> I'd expect that Django would log something like:
>
> * At INFO level, at least one line per request (similar to runserver
> output)
> * At DEBUG level, enough information to recreate the request
>
> However, it doesn't appear to:
>
> * There are only two logger.debug statements, both logging database SQL
> commands
> * There are no logger.info statements at all
> * Turning on DEBUG logging for everything seems to log only SQL statements
> and errors
> * The django.request logger only seems to be used for errors and warnings
>
> I'd like to add more info and debug logging to django.request as stated
> above. Is that likely to be accepted?
>

A definite "Maybe". :-)

For my money, this is probably something that is handled better by the web
server. Apache, for example, logs one line per request, and can be
configured to dump full GET and POST contents if you need that information.

Aside from reproducing functionality available elsewhere, my concern would
be performance. Adding a single logging call isn't much, but you're adding
it into a critical path, so the impact could be large (especially if you're
logging the full contents of POST and FILES data).

So - I'm probably wavering between a +0 and -0, depending on the actual
impact your proposed change has.

At the very least, it's worth opening a ticket -- even if the idea is
ultimately rejected, a ticket allows us to archive the decision making
process (since I doubt you're the first, or will be the last person to
think of this idea).

Yours,
Russ Magee %-)

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAJxq849GkU664Mb-gMbBs0moZjVaWPGCvr5pb2-TzUg4s_O%2BhQ%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to