Metadata-Version: 1.0
Name: ConcurrentLogHandler
Version: 0.7.4
Summary:  Concurrent logging handler (drop-in replacement for RotatingFileHandler)
Home-page: http://pypi.python.org/pypi/ConcurrentLogHandler
Author: Lowell Alleman
Author-email: lowell87@gmail.com
License: http://www.apache.org/licenses/LICENSE-2.0
Description: Overview
        ========
        This module provides an additional log handler for Python's standard logging
        package (PEP 282). This handler will write a log entries to a set of files,
        which switches from one file to the next when the current file reaches a certain
        size.  Multiple processes can write to the log file concurrently.
        
        Details
        =======
        The ``ConcurrentRotatingFileHandler`` class is a drop-in replacement for
        Python's standard log handler ``RotatingFileHandler``. This module uses file
        locking so that multiple processes can concurrently log to a single file without
        dropping or clobbering log records. This module provides a file rotation scheme
        like ``RotatingFileHanler``, except that extra care is taken to ensure that logs
        can be safely rotated before the rotation process is started. (This module works
        around the file rename issue with ``RotatingFileHandler`` on Windows, where a
        rotation failure means that all subsequent logs are lost).
        
        This module's attempts to preserve log records at all cost. This means that log
        files will grow larger than the specified maximum (rotation) size. So if disk
        space is tight, you may want to stick with ``RotatingFileHandler``, which will
        strictly adhere to the maximum file size.
        
        
        Installation
        ============
        Use the following command to install this package::
        
        easy_install ConcurrentLogHandler
        
        
        Simple example
        ==============
        Here is a example demonstrating how to use this module::
        
        from logging import getLogger, INFO
        from cloghandler import ConcurrentRotatingFileHandler
        import os
        
        log = getLogger()
        # Use an absolute path to prevent file rotation trouble.
        logfile = os.path.abspath("mylogfile.log")
        # Rotate log after reaching 512K, keep 5 old copies.
        rotateHandler = ConcurrentRotatingFileHandler(logfile, "a", 512*1024, 5)
        log.addHandler(rotateHandler)
        log.setLevel(INFO)
        
        log.info("Here is a very exciting log message, just for you")
        
Platform: nt
Platform: posix
Classifier: Development Status :: 4 - Beta
Classifier: Topic :: System :: Logging
Classifier: Operating System :: POSIX
Classifier: Operating System :: Microsoft :: Windows
Classifier: Programming Language :: Python
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: License :: OSI Approved :: Apache Software License
