summaryrefslogtreecommitdiffstats
path: root/aai-els-onap-logging
diff options
context:
space:
mode:
authorFiete Ostkamp <Fiete.Ostkamp@telekom.de>2022-10-14 09:30:31 +0000
committerFiete Ostkamp <Fiete.Ostkamp@telekom.de>2022-10-14 09:30:31 +0000
commitd629b626036a1ef1bc37e2b9aa5b5d2fcad1be66 (patch)
treebbb64ce713a6f3407d73ed256d48a5c83da1cdf3 /aai-els-onap-logging
parent271e8f5f853c7ed8c277f5c12607a4633dd5b136 (diff)
Remove the apache commons-lang dependency in aai-common
Issue-ID: AAI-3551 Signed-off-by: Fiete Ostkamp <Fiete.Ostkamp@telekom.de> Change-Id: Ib68b6fb43044532abf39c1ac088ef969c5aa00c2
Diffstat (limited to 'aai-els-onap-logging')
-rw-r--r--aai-els-onap-logging/pom.xml10
-rw-r--r--aai-els-onap-logging/src/main/java/org/onap/aai/logging/ErrorLogHelper.java27
-rw-r--r--aai-els-onap-logging/src/main/java/org/onap/aai/logging/LogFormatTools.java10
-rw-r--r--aai-els-onap-logging/src/main/java/org/onap/aai/util/AAIApplicationConfig.java12
-rw-r--r--aai-els-onap-logging/src/test/java/org/onap/aai/util/LogFile.java6
5 files changed, 34 insertions, 31 deletions
diff --git a/aai-els-onap-logging/pom.xml b/aai-els-onap-logging/pom.xml
index 9f180bbb..49fac945 100644
--- a/aai-els-onap-logging/pom.xml
+++ b/aai-els-onap-logging/pom.xml
@@ -1,7 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://maven.apache.org/POM/4.0.0"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.aai.aai-common</groupId>
@@ -116,8 +114,8 @@
<artifactId>jackson-module-jaxb-annotations</artifactId>
</dependency>
<dependency>
- <groupId>commons-lang</groupId>
- <artifactId>commons-lang</artifactId>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>commons-lang3</artifactId>
</dependency>
<dependency>
<groupId>commons-io</groupId>
@@ -145,4 +143,4 @@
</exclusions>
</dependency>
</dependencies>
-</project>
+</project> \ No newline at end of file
diff --git a/aai-els-onap-logging/src/main/java/org/onap/aai/logging/ErrorLogHelper.java b/aai-els-onap-logging/src/main/java/org/onap/aai/logging/ErrorLogHelper.java
index 4ef2a237..1bc33f49 100644
--- a/aai-els-onap-logging/src/main/java/org/onap/aai/logging/ErrorLogHelper.java
+++ b/aai-els-onap-logging/src/main/java/org/onap/aai/logging/ErrorLogHelper.java
@@ -20,7 +20,22 @@
package org.onap.aai.logging;
-import org.apache.commons.lang.StringUtils;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.StringWriter;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map.Entry;
+import java.util.Properties;
+
+import javax.ws.rs.core.MediaType;
+import javax.xml.bind.JAXBContext;
+import javax.xml.bind.Marshaller;
+
+import org.apache.commons.lang3.StringUtils;
import org.onap.aai.exceptions.AAIException;
import org.onap.aai.util.AAIConstants;
import org.onap.aai.util.MapperUtil;
@@ -31,16 +46,6 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.slf4j.MDC;
-import javax.ws.rs.core.MediaType;
-import javax.xml.bind.JAXBContext;
-import javax.xml.bind.Marshaller;
-import java.io.FileInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.StringWriter;
-import java.util.*;
-import java.util.Map.Entry;
-
/**
*
* This classes loads the application error properties file
diff --git a/aai-els-onap-logging/src/main/java/org/onap/aai/logging/LogFormatTools.java b/aai-els-onap-logging/src/main/java/org/onap/aai/logging/LogFormatTools.java
index 3f0d80ae..caf8e7c8 100644
--- a/aai-els-onap-logging/src/main/java/org/onap/aai/logging/LogFormatTools.java
+++ b/aai-els-onap-logging/src/main/java/org/onap/aai/logging/LogFormatTools.java
@@ -20,16 +20,16 @@
package org.onap.aai.logging;
-import org.apache.commons.lang.exception.ExceptionUtils;
-import org.onap.aai.exceptions.AAIException;
-import org.onap.aai.util.AAIConfig;
-import org.onap.aai.util.AAIConstants;
-
import java.time.Instant;
import java.time.ZoneOffset;
import java.time.ZonedDateTime;
import java.time.format.DateTimeFormatter;
+import org.apache.commons.lang3.exception.ExceptionUtils;
+import org.onap.aai.exceptions.AAIException;
+import org.onap.aai.util.AAIConfig;
+import org.onap.aai.util.AAIConstants;
+
public class LogFormatTools {
private static final String DATE_FORMAT = "yyyy-MM-dd'T'HH:mm:ss.SSSZ";
diff --git a/aai-els-onap-logging/src/main/java/org/onap/aai/util/AAIApplicationConfig.java b/aai-els-onap-logging/src/main/java/org/onap/aai/util/AAIApplicationConfig.java
index 9232b1c8..93969795 100644
--- a/aai-els-onap-logging/src/main/java/org/onap/aai/util/AAIApplicationConfig.java
+++ b/aai-els-onap-logging/src/main/java/org/onap/aai/util/AAIApplicationConfig.java
@@ -20,12 +20,6 @@
package org.onap.aai.util;
-import org.apache.commons.io.IOUtils;
-import org.eclipse.jetty.util.security.Password;
-import org.onap.aai.exceptions.AAIException;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
@@ -35,6 +29,12 @@ import java.util.Properties;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import org.apache.commons.io.IOUtils;
+import org.eclipse.jetty.util.security.Password;
+import org.onap.aai.exceptions.AAIException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
public class AAIApplicationConfig {
private static final Logger LOGGER = LoggerFactory.getLogger(AAIApplicationConfig.class);
diff --git a/aai-els-onap-logging/src/test/java/org/onap/aai/util/LogFile.java b/aai-els-onap-logging/src/test/java/org/onap/aai/util/LogFile.java
index 682f667b..b94686bb 100644
--- a/aai-els-onap-logging/src/test/java/org/onap/aai/util/LogFile.java
+++ b/aai-els-onap-logging/src/test/java/org/onap/aai/util/LogFile.java
@@ -19,14 +19,14 @@
*/
package org.onap.aai.util;
-import org.apache.commons.io.FileUtils;
-import org.apache.commons.io.IOUtils;
-
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.nio.charset.Charset;
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.io.IOUtils;
+
/**
* Utility class to read/delete contents of log file
*/