From f54e335ef68b28e087fb8625098fc49bd285b4d4 Mon Sep 17 00:00:00 2001 From: Vidya Shinde Date: Fri, 11 Aug 2017 15:11:49 +0530 Subject: [LOG] Add canonicalization for VID logs Canonicalization of path for log provider configuration file and log files Change-Id: Ifc7fec117f7d6f2fcb7a67b0861582ce5f50342f Issue-ID: LOG-27 Signed-off-by: Vidya Shinde --- onap/vid/README.md | 20 ++++ onap/vid/conf/logback.xml | 299 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 319 insertions(+) create mode 100644 onap/vid/README.md create mode 100644 onap/vid/conf/logback.xml (limited to 'onap/vid') diff --git a/onap/vid/README.md b/onap/vid/README.md new file mode 100644 index 0000000..05c5a0a --- /dev/null +++ b/onap/vid/README.md @@ -0,0 +1,20 @@ +############################################################################################################################################## +## VID logging configuration +===================================================================================== +VID has two docker containers - vid-server and vid-mariadb. +The canonical logging implementation is only done for the container, vid-server. +Canonical logs will be generated at /var/log/onap/vid/ +================================================================================================= +## Instructions for deployment +================================================================================================= + 1. Log provider file is available at the path, /tomcat/webapps/vid/WEB-INF/classes/, in the container + 2. Copy the canonical logback.xml from 'vid' directory (of gerrit) into the path mentioned in step 1. + 3. Create the canonical path, /var/log/onap/vid/, on the host VM. + 4. Provide write permissions for "others" user for directory created in step 3. + 5. Volume-Mount: The vid-server container requires one host path mapped as volume in the container + 5.1. Log file path: + Host path - /var/log/onap/vid/ mapped to + Container path - /var/log/onap/vid/ + 5.2. Log Provider file path: + Note: Log provider path cannot be configured externally as it is bundled inside a WAR. +############################################################################################################################################## diff --git a/onap/vid/conf/logback.xml b/onap/vid/conf/logback.xml new file mode 100644 index 0000000..5656303 --- /dev/null +++ b/onap/vid/conf/logback.xml @@ -0,0 +1,299 @@ + + + + + + + + + + + + + + + + + + + + + + + + + ${pattern} + + + + + + + + ${logDirectory}/${generalLogName}.log + + ${logDirectory}/${generalLogName}.%d{yyyy-MM-dd}.%i.log + + ${maxFileSize} + + ${maxHistory} + ${totalSizeCap} + + + ${pattern} + + + + + ${queueSize} + true + + + + + + + + + + + + + ${logDirectory}/${auditLogName}.log + + ${logDirectory}/${auditLogName}.%d{yyyy-MM-dd}.%i.log + + ${maxFileSize} + + ${maxHistory} + ${totalSizeCap} + + + ${pattern} + + + + ${queueSize} + + + + ${logDirectory}/${metricsLogName}.log + + ${logDirectory}/${metricsLogName}.%d{yyyy-MM-dd}.%i.log + + ${maxFileSize} + + ${maxHistory} + ${totalSizeCap} + + + ${pattern} + + + + ${queueSize} + + + + ${logDirectory}/${errorLogName}.log + + ${logDirectory}/${errorLogName}.%d{yyyy-MM-dd}.%i.log + + ${maxFileSize} + + ${maxHistory} + ${totalSizeCap} + + + ${pattern} + + + + ${queueSize} + + + + ${logDirectory}/${debugLogName}.log + + ${logDirectory}/${debugLogName}.%d{yyyy-MM-dd}.%i.log + + ${maxFileSize} + + ${maxHistory} + ${totalSizeCap} + + + ${pattern} + + + + ${queueSize} + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file -- cgit 1.2.3-korg