From c97bfeca3abd74392b89eae252759d3c4d82baf9 Mon Sep 17 00:00:00 2001 From: Fiete Ostkamp Date: Thu, 4 Jan 2024 13:35:54 +0100 Subject: Add spring-cloud-sleuth for tracing - add tracing dependencies - align localhost-access-logback.xml with the one in the oom chart - bump version to 1.13.1 Issue-ID: AAI-3714 Change-Id: I6565d63f070bbd04188f383fc88ea9ca884951dd Signed-off-by: Fiete Ostkamp --- aai-traversal/pom.xml | 18 +++- .../src/main/resources/application.properties | 8 ++ .../main/resources/localhost-access-logback.xml | 114 +++++++++++++-------- pom.xml | 2 +- version.properties | 2 +- 5 files changed, 96 insertions(+), 48 deletions(-) diff --git a/aai-traversal/pom.xml b/aai-traversal/pom.xml index 125edea..b2da78a 100644 --- a/aai-traversal/pom.xml +++ b/aai-traversal/pom.xml @@ -26,7 +26,7 @@ org.onap.aai.traversal traversal - 1.13.0-SNAPSHOT + 1.13.1-SNAPSHOT org.onap.aai.traversal aai-traversal @@ -96,6 +96,7 @@ 2.4.13 5.3.13 + 2020.0.2 ${spring.version} ${spring.version} 4.0.1 @@ -684,6 +685,14 @@ spring-boot-starter-jetty + org.springframework.cloud + spring-cloud-starter-sleuth + + + org.springframework.cloud + spring-cloud-sleuth-zipkin + + org.springframework.boot spring-boot-starter-test test @@ -792,6 +801,13 @@ pom import + + org.springframework.cloud + spring-cloud-dependencies + ${spring-cloud.version} + pom + import + diff --git a/aai-traversal/src/main/resources/application.properties b/aai-traversal/src/main/resources/application.properties index 5e49d18..e624e96 100644 --- a/aai-traversal/src/main/resources/application.properties +++ b/aai-traversal/src/main/resources/application.properties @@ -8,6 +8,14 @@ spring.application.name=aai-traversal spring.jersey.type=filter spring.main.allow-bean-definition-overriding=true +spring.zipkin.baseUrl=http://jaeger-collector.istio-system:9411 +spring.sleuth.messaging.jms.enabled=false +spring.sleuth.trace-id128=true +spring.sleuth.sampler.probability=1.0 +spring.sleuth.propagation.type=w3c,b3 +spring.sleuth.supports-join=false +spring.sleuth.web.skip-pattern=/aai/util.* + server.servlet.context-path=${schema.uri.base.path} spring.autoconfigure.exclude=\ org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration,\ diff --git a/aai-traversal/src/main/resources/localhost-access-logback.xml b/aai-traversal/src/main/resources/localhost-access-logback.xml index cb0b9a6..35a2c5c 100644 --- a/aai-traversal/src/main/resources/localhost-access-logback.xml +++ b/aai-traversal/src/main/resources/localhost-access-logback.xml @@ -1,54 +1,78 @@ - - - - - - ${AJSC_HOME}/logs/ajsc-jetty/localhost_access.log - - ${AJSC_HOME}/logs/ajsc-jetty/localhost_access.log.%d{yyyy-MM-dd} - - ${maxHistory} - ${totalSizeCap} - - - %a %u %z [%t] "%m %U%q" %s %b %y %i{X-TransactionId} %i{X-FromAppId} %i{X-Forwarded-For} %i{X-AAI-SSL-Client-CN} %i{X-AAI-SSL-Client-OU} %i{X-AAI-SSL-Client-O} %i{X-AAI-SSL-Client-L} %i{X-AAI-SSL-Client-ST} %i{X-AAI-SSL-Client-C} %i{X-AAI-SSL-Client-NotBefore} %i{X-AAI-SSL-Client-NotAfter} %i{X-AAI-SSL-Client-DN} %D - - - + + + + + + - - - %a %u %z [%t] "%m %U%q" %s %b %y %i{X-TransactionId} %i{X-FromAppId} %i{X-Forwarded-For} %i{X-AAI-SSL-Client-CN} %i{X-AAI-SSL-Client-OU} %i{X-AAI-SSL-Client-O} %i{X-AAI-SSL-Client-L} %i{X-AAI-SSL-Client-ST} %i{X-AAI-SSL-Client-C} %i{X-AAI-SSL-Client-NotBefore} %i{X-AAI-SSL-Client-NotAfter} %i{X-AAI-SSL-Client-DN} %D - "logType": "access" - - - + + + + ${AJSC_HOME}/logs/ajsc-jetty/localhost_access.log + + ${AJSC_HOME}/logs/ajsc-jetty/localhost_access.log.%d{yyyy-MM-dd} + + ${maxHistory} + ${totalSizeCap} + + + %a %u %z [%t] "%m %U%q" %s %b %y %i{X-TransactionId} %i{X-FromAppId} + %i{X-Forwarded-For} %i{X-AAI-SSL-Client-CN} %i{X-AAI-SSL-Client-OU} + %i{X-AAI-SSL-Client-O} %i{X-AAI-SSL-Client-L} %i{X-AAI-SSL-Client-ST} + %i{X-AAI-SSL-Client-C} %i{X-AAI-SSL-Client-NotBefore} %i{X-AAI-SSL-Client-NotAfter} + %i{X-AAI-SSL-Client-DN} %D + + + + + + + + + %a %u %z [%t] "%m %U%q" %s %b %y %i{X-TransactionId} %i{X-FromAppId} + %i{X-Forwarded-For} %i{X-AAI-SSL-Client-CN} %i{X-AAI-SSL-Client-OU} %i{X-AAI-SSL-Client-O} + %i{X-AAI-SSL-Client-L} %i{X-AAI-SSL-Client-ST} %i{X-AAI-SSL-Client-C} + %i{X-AAI-SSL-Client-NotBefore} %i{X-AAI-SSL-Client-NotAfter} %i{X-AAI-SSL-Client-DN} %D - + "logType": "access" + + + + + + /aai/util/echo + + NEUTRAL + DENY + + + + + - \ No newline at end of file +--> \ No newline at end of file diff --git a/pom.xml b/pom.xml index a820c3b..cf67554 100644 --- a/pom.xml +++ b/pom.xml @@ -30,7 +30,7 @@ org.onap.aai.traversal traversal - 1.13.0-SNAPSHOT + 1.13.1-SNAPSHOT aai-traversal pom diff --git a/version.properties b/version.properties index 39cb3bf..0c0fa8e 100644 --- a/version.properties +++ b/version.properties @@ -5,7 +5,7 @@ major_version=1 minor_version=13 -patch_version=0 +patch_version=1 base_version=${major_version}.${minor_version}.${patch_version} -- cgit 1.2.3-korg