#NEWLINE# def __init__( self , appid = None , logger_root = 'cherrypy' ) : #NEWLINE# #INDENT# self . logger_root = logger_root #NEWLINE# self . appid = appid #NEWLINE# if ( appid is None ) : #NEWLINE# #INDENT# self . error_log = logging . getLogger ( ( '%s.error' % logger_root ) ) #NEWLINE# self . access_log = logging . getLogger ( ( '%s.access' % logger_root ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . error_log = logging . getLogger ( ( '%s.error.%s' % ( logger_root , self ) ) ) #NEWLINE# self . access_log = logging . getLogger ( ( '%s.access.%s' % ( logger_root , appid ) ) ) #NEWLINE# #UNINDENT# self . error_log . setLevel ( logging . INFO ) #NEWLINE# self . access_log . setLevel ( logging . INFO ) #NEWLINE# self . error_log . addHandler ( NullHandler ( ) ) #NEWLINE# self . access_log . addHandler ( NullHandler ( ) ) #NEWLINE# cherrypy . engine . subscribe ( 'graceful' , self . reopen_files )