From 32baac85b1aef6d8e47a6ae3b8c2f04c8792435b Mon Sep 17 00:00:00 2001
From: Sherman Yang <SYang@slb.com>
Date: Mon, 4 Jan 2021 10:19:18 -0600
Subject: [PATCH] support azure request logs

---
 .../crs-converter-azure/crs-converter-aks/pom.xml   | 13 +++++++++++++
 .../src/main/resources/application.yaml             |  9 +++++++++
 2 files changed, 22 insertions(+)

diff --git a/provider/crs-converter-azure/crs-converter-aks/pom.xml b/provider/crs-converter-azure/crs-converter-aks/pom.xml
index 5bfec907..9c50f212 100644
--- a/provider/crs-converter-azure/crs-converter-aks/pom.xml
+++ b/provider/crs-converter-azure/crs-converter-aks/pom.xml
@@ -15,6 +15,7 @@
         <app.version>1</app.version>
         <app.id>crs-converter-aks</app.id>
         <azure.version>2.3.2</azure.version>
+        <osdu.corelibazure.version>0.0.42</osdu.corelibazure.version>
     </properties>
 
     <prerequisites>
@@ -33,10 +34,22 @@
             <version>1.0.0</version>
         </dependency>
         
+        <dependency>
+            <groupId>org.opengroup.osdu</groupId>
+            <artifactId>core-lib-azure</artifactId>
+            <version>${osdu.corelibazure.version}</version>
+        </dependency>
+        
         <dependency>
             <groupId>com.microsoft.azure</groupId>
             <artifactId>azure-active-directory-spring-boot-starter</artifactId>
             <version>${azure.version}</version>
+            <exclusions>
+                <exclusion>
+                    <groupId>org.springframework.boot</groupId>
+                    <artifactId>spring-boot-starter-logging</artifactId>
+                </exclusion>
+            </exclusions>
         </dependency>
         
         <dependency>
diff --git a/provider/crs-converter-azure/crs-converter-aks/src/main/resources/application.yaml b/provider/crs-converter-azure/crs-converter-aks/src/main/resources/application.yaml
index c58ab64b..655e04fe 100644
--- a/provider/crs-converter-azure/crs-converter-aks/src/main/resources/application.yaml
+++ b/provider/crs-converter-azure/crs-converter-aks/src/main/resources/application.yaml
@@ -14,5 +14,14 @@ logging:
     org:
       springframework:
         web: INFO
+  transaction:
+    enabled: true
+  slf4jlogger:
+    enabled: true
+  mdccontext:
+    enabled: true
 LOG_PREFIX: converter
 
+azure:
+  application-insights:
+    instrumentation-key: ${appinsights_key}
-- 
GitLab