From d8ca55c685d167e5c5cc6980939ae6c78840ed7d Mon Sep 17 00:00:00 2001 From: Rahul Khiyani Date: Tue, 12 Feb 2019 11:13:04 -0500 Subject: [PATCH] Logs format standardization for LMA component Added file name, line number and function name to logging message format for troubleshooting purpose - This change is related to Grafana's session-db-sync job Change-Id: Iaadbedfda0fd9cd7fe4b5c09fc05cb6181c400d1 --- grafana/templates/bin/_db-session-sync.py.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/grafana/templates/bin/_db-session-sync.py.tpl b/grafana/templates/bin/_db-session-sync.py.tpl index 739478b8a..cb325e6ea 100644 --- a/grafana/templates/bin/_db-session-sync.py.tpl +++ b/grafana/templates/bin/_db-session-sync.py.tpl @@ -19,7 +19,7 @@ logger = logging.getLogger('OpenStack-Helm DB Init') logger.setLevel(logging.DEBUG) ch = logging.StreamHandler() ch.setLevel(logging.DEBUG) -formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s') +formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(filename)s - %(lineno)d - %(funcName)s - %(message)s') # Set the formatter and add the handler ch.setFormatter(formatter)