This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vinay.sajip
Recipients azsorkin, dasilver@cisco.com, r.david.murray, rhettinger, vinay.sajip
Date 2015-10-09.07:25:38
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1444375538.29.0.791472793558.issue25344@psf.upfronthosting.co.za>
In-reply-to
Content
This is already supported. There is a logging.handlers.MemoryHandler which allows you to buffer logging events and then pass the buffered events to another handler when some condition is met, such as e.g. buffer full or some severity threshold is exceeded. Flushing the buffer to the other handler can be customised by subclassing and overriding shouldFlush() and perhaps flush() methods.

https://docs.python.org/2/library/logging.handlers.html#memoryhandler

I can perhaps add a cookbook recipe to illustrate, so I'll leave this issue open for now, as a reminder.
History
Date User Action Args
2015-10-09 07:25:38vinay.sajipsetrecipients: + vinay.sajip, rhettinger, r.david.murray, azsorkin, dasilver@cisco.com
2015-10-09 07:25:38vinay.sajipsetmessageid: <1444375538.29.0.791472793558.issue25344@psf.upfronthosting.co.za>
2015-10-09 07:25:38vinay.sajiplinkissue25344 messages
2015-10-09 07:25:38vinay.sajipcreate