aboutsummaryrefslogtreecommitdiffstats
path: root/prh-app-server/src/main/resources
diff options
context:
space:
mode:
authormicdzied <michal.1.dziedzic@nokia.com>2018-08-30 10:25:19 +0200
committermicdzied <michal.1.dziedzic@nokia.com>2018-08-30 14:53:20 +0200
commit6fd8c7770fbea30ad2ec6e3f7645b8baab5a49a1 (patch)
tree78d572b5df8c88047d74edf3c75b28fcab3d0dc6 /prh-app-server/src/main/resources
parent82a6fc31d1905f380fbbae1d0b4a34b67d8258e3 (diff)
add MDC's
Change-Id: Ie4fe86791f46b790ae42088a5d2b93f491e4549d Issue-ID: DCAEGEN2-730 Signed-off-by: micdzied <michal.1.dziedzic@nokia.com>
Diffstat (limited to 'prh-app-server/src/main/resources')
-rw-r--r--prh-app-server/src/main/resources/application.properties4
-rw-r--r--prh-app-server/src/main/resources/logback-spring.xml18
-rw-r--r--prh-app-server/src/main/resources/scheduled-context.xml10
3 files changed, 19 insertions, 13 deletions
diff --git a/prh-app-server/src/main/resources/application.properties b/prh-app-server/src/main/resources/application.properties
index fa38d188..ac0192ca 100644
--- a/prh-app-server/src/main/resources/application.properties
+++ b/prh-app-server/src/main/resources/application.properties
@@ -9,4 +9,6 @@ logging.level.root=ERROR
logging.level.org.springframework=ERROR
logging.level.org.springframework.data=ERROR
logging.level.org.onap.dcaegen2.services.prh=INFO
-app.filepath=config/prh_endpoints.json \ No newline at end of file
+app.filepath=config/prh_endpoints.json
+app.xonaprequestid=requestID
+app.xinvocationid=invocationID
diff --git a/prh-app-server/src/main/resources/logback-spring.xml b/prh-app-server/src/main/resources/logback-spring.xml
index 74c386b6..427373fd 100644
--- a/prh-app-server/src/main/resources/logback-spring.xml
+++ b/prh-app-server/src/main/resources/logback-spring.xml
@@ -1,7 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<include resource="org/springframework/boot/logging/logback/defaults.xml"/>
- <property name="LOG_FILE" value="${LOG_FILE:-${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}}/spring.log}"/>
+ <property name="LOG_FILE"
+ value="${LOG_FILE:-${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}}/spring.log}"/>
<property name="FILE_LOG_PATTERN" value="${CONSOLE_LOG_PATTERN}"/>
<Property name="outputFilename" value="prh-app-server_output"/>
<Property name="log-path" value="/var/log/ONAP/prh/prh-app-server"/>
@@ -11,7 +12,7 @@
<property name="totalSizeCap" value="10GB"/>
<springProfile name="dev">
- <appender name="CONSOLE" target="SYSTEM_OUT" class="ch.qos.logback.core.ConsoleAppender">
+ <appender class="ch.qos.logback.core.ConsoleAppender" name="CONSOLE" target="SYSTEM_OUT">
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<Pattern>%nopexception%logger
|%date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX,UTC}
@@ -21,10 +22,11 @@
|%replace(%replace(%rootException){'\t','\\\\t'}){'\n','\\\\n'}
|%replace(%replace(%marker){'\t','\\\\t'}){'\n','\\\\n'}
|%thread
- |%n</Pattern>
+ |%n
+ </Pattern>
</encoder>
</appender>
- <appender name="ROLLING-FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <appender class="ch.qos.logback.core.rolling.RollingFileAppender" name="ROLLING-FILE">
<encoder>
<pattern>%nopexception%logger
|%date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX,UTC}
@@ -34,7 +36,8 @@
|%replace(%replace(%rootException){'\t','\\\\t'}){'\n','\\\\n'}
|%replace(%replace(%marker){'\t','\\\\t'}){'\n','\\\\n'}
|%thread
- |%n</pattern>
+ |%n
+ </pattern>
</encoder>
<file>${LOG_FILE}</file>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
@@ -51,7 +54,7 @@
</springProfile>
<springProfile name="prod">
- <appender name="ROLLING-FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
+ <appender class="ch.qos.logback.core.rolling.RollingFileAppender" name="ROLLING-FILE">
<encoder>
<pattern>%nopexception%logger
|%date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX,UTC}
@@ -61,7 +64,8 @@
|%replace(%replace(%rootException){'\t','\\\\t'}){'\n','\\\\n'}
|%replace(%replace(%marker){'\t','\\\\t'}){'\n','\\\\n'}
|%thread
- |%n</pattern>
+ |%n
+ </pattern>
</encoder>
<File>${log-path}/${outputFilename}.log</File>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
diff --git a/prh-app-server/src/main/resources/scheduled-context.xml b/prh-app-server/src/main/resources/scheduled-context.xml
index 91919aa2..82067c17 100644
--- a/prh-app-server/src/main/resources/scheduled-context.xml
+++ b/prh-app-server/src/main/resources/scheduled-context.xml
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
-<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+<beans xmlns:context="http://www.springframework.org/schema/context"
xmlns:task="http://www.springframework.org/schema/task"
- xmlns:context="http://www.springframework.org/schema/context"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns="http://www.springframework.org/schema/beans"
xsi:schemaLocation="http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task-4.0.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd">
@@ -10,7 +10,7 @@
<context:component-scan
base-package="org.onap.dcaegen2.services.prh"/>
<task:scheduled-tasks>
- <task:scheduled ref="scheduleController" method="startTasks"
- fixed-rate="1000"/>
+ <task:scheduled fixed-rate="1000" method="startTasks"
+ ref="scheduleController"/>
</task:scheduled-tasks>
</beans>