If you're running standalone WSGI you could pipe output to Apache's rotatelogs or to cronolog. There may be other generic log rotation subprocesses you can use. They're very reliable.
For a straight WSGI server I wrote a logging handler to synchronize logging between threads & processes, which doesn't involve rename for log file rotation ( logs instead to files created with date or time stamps as part of their filenames -- the alternative was a log.lck file to synchronize log file rotation/creation). The same method ( indeed the same code -- since it plugs into Python's standard logging framework ) would be fine for Django as well. Perhaps I didn't dig deeply enough -- these things aren't hard to write -- but the python std logging library doesn't seem to offer a multiprocessing safe logging handler -- which is odd, since it is essential in a multiprocess environment. ( A multiprocess environment in turn is essential due to the impairment Python's GIL places on concurrency ) Lokesh Maremalla wrote: > Hi, > > Included django-logging as described in the link. > > From the django-logging I can view the log messages on the screen at > run time. But, I am not sure on saving the log messages from > django-logging. > Can I capture the log messages into my log file on a daily basis > instead of redirecting to screen. > > Regards, > Lokesh > > On Mon, Aug 17, 2009 at 9:16 PM, Mike Ramirez <gufym...@gmail.com > <mailto:gufym...@gmail.com>> wrote: > > On Monday 17 August 2009 07:56:48 am Lokesh wrote: > > Hi, > > > > I am trying to implement the logging (Code flow tracking) for my > > Django application. > > I would like to store the log messages on daily basis for my > > applications. > > > > Need help or suggestions on how we can implement the logging > mechanism > > for an application. > > > > Regards, > > Lokesh > > > You can look at django-logging [1], it intergrates the python > logging module > with django as middleware. > > [1] http://code.google.com/p/django-logging/wiki/Overview > > Mike > > -- > I feel like I am sharing a ``CORN-DOG'' with NIKITA KHRUSCHEV ... > > > > > -- > Thanks & Regards, > Lokesh. > lokeshmarema...@gmail.com <mailto:lokeshmarema...@gmail.com> > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---
<<attachment: rmela.vcf>>