Use rotating file handler for logging

closes #1204
This commit is contained in:
Sylvain Bellemare 2017-04-13 15:25:00 +02:00 committed by Sylvain Bellemare
parent df02a77788
commit 7701963f5e

View File

@ -41,9 +41,11 @@ SUBSCRIBER_LOGGING_CONFIG = {
'level': logging.INFO, 'level': logging.INFO,
}, },
'file': { 'file': {
'class': 'logging.FileHandler', 'class': 'logging.RotatingFileHandler',
'filename': join(DEFAULT_LOG_DIR, 'bigchaindb.log'), 'filename': join(DEFAULT_LOG_DIR, 'bigchaindb.log'),
'mode': 'w', 'mode': 'w',
'maxBytes': 209715200,
'backupCount': 5,
'formatter': 'file', 'formatter': 'file',
'level': logging.INFO, 'level': logging.INFO,
}, },