Commit e500f74f authored by Aryaan Singh's avatar Aryaan Singh
Browse files

Merge branch 'm8-log4j2fix' into 'Azure/OSDU-Notification-M8-Master'

M8 Log4j2 Fix

See merge request !161
parents 86c45da5 16007485
Pipeline #95049 passed with stages
in 19 minutes and 22 seconds
......@@ -22,4 +22,4 @@ image:
branch: master
tag: latest
istioDnsHost: ""
\ No newline at end of file
istioDnsHost: "contoso.com"
\ No newline at end of file
......@@ -38,8 +38,39 @@
<springfox-version>2.7.0</springfox-version>
<netty.version>4.1.65.Final</netty.version>
<undertow.version>2.1.7.Final</undertow.version>
<log4j2.version>2.17.0</log4j2.version>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-to-slf4j</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-jul</artifactId>
<version>${log4j2.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>org.opengroup.osdu</groupId>
......
......@@ -49,6 +49,7 @@
<reactor-core.version>3.4.6</reactor-core.version>
<reactor-netty.version>1.0.7</reactor-netty.version>
<oauth2-oidc-sdk.version>6.0</oauth2-oidc-sdk.version>
<log4j2.version>2.17.0</log4j2.version>
</properties>
<dependencyManagement>
......@@ -68,6 +69,31 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-to-slf4j</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-jul</artifactId>
<version>${log4j2.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
......
......@@ -36,8 +36,39 @@
<java.version>8</java.version>
<maven.compiler.target>${java.version}</maven.compiler.target>
<maven.compiler.source>${java.version}</maven.compiler.source>
<log4j2.version>2.17.0</log4j2.version>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-to-slf4j</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-jul</artifactId>
<version>${log4j2.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>org.opengroup.osdu.notification</groupId>
......
......@@ -148,7 +148,8 @@ public class TestStorageIntegration extends BaseTestTemplate {
// The Test Ack Subscription gets created if the the test endpoint of actual subscription
// created above receives notification from Notification Service.
this.deleteAckSubscription();
// Delete legal tag
LegalTagUtils.delete(LEGAL_TAG, this.testUtils.getAdminToken());
// Create legal tag used in storage record
LegalTagUtils.create(LEGAL_TAG, this.testUtils.getAdminToken());
......
......@@ -22,7 +22,7 @@ import org.apache.http.HttpStatus;
import java.util.HashMap;
import java.util.Map;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.*;
public class LegalTagUtils {
public static ClientResponse create(String legalTagName, String token) throws Exception {
......@@ -35,7 +35,7 @@ public class LegalTagUtils {
Map<String, String> headers = new HashMap<>();
headers.put("Data-Partition-Id", TestUtils.getOsduTenant());
ClientResponse response = TestUtils.send(getLegalUrl(), "legaltags", "POST", token, body, "", headers, false);
assertEquals(HttpStatus.SC_CREATED, response.getStatus());
assertTrue(response.getStatus()==HttpStatus.SC_CREATED ||response.getStatus()==HttpStatus.SC_CONFLICT );
Thread.sleep(100);
return response;
}
......
......@@ -36,8 +36,39 @@
<java.version>8</java.version>
<maven.compiler.target>${java.version}</maven.compiler.target>
<maven.compiler.source>${java.version}</maven.compiler.source>
<log4j2.version>2.17.0</log4j2.version>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-to-slf4j</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-jul</artifactId>
<version>${log4j2.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>javax.xml.bind</groupId>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment