diff options
author | 2024-09-18 16:06:17 +0200 | |
---|---|---|
committer | 2024-09-18 16:06:17 +0200 | |
commit | 03d5651e76a712af7a0ee04050e42b80dc43704b (patch) | |
tree | 794b1078ef73bb11fb48e2d5c5fb30b2b7ead9a2 /src/main/java/org/onap | |
parent | 610846c7e9e48806073e15ede8e502119c587ca3 (diff) |
Use Java 11 in graphadmin1.14.7
- switch compiler version and base image to Java 11
- remove com.sun.jersey (Jersey 1) dependencies
- replace heap_size jvm args with MaxRAMPercentage to scale dynamically with the K8s limits
Issue-ID: AAI-4001
Change-Id: I17d126cf9972bad4c851a374113845be77fee9f6
Signed-off-by: Fiete Ostkamp <Fiete.Ostkamp@telekom.de>
Diffstat (limited to 'src/main/java/org/onap')
4 files changed, 31 insertions, 33 deletions
diff --git a/src/main/java/org/onap/aai/db/schema/AuditDoc.java b/src/main/java/org/onap/aai/db/schema/AuditDoc.java index 2beec12..0d828ca 100644 --- a/src/main/java/org/onap/aai/db/schema/AuditDoc.java +++ b/src/main/java/org/onap/aai/db/schema/AuditDoc.java @@ -19,16 +19,16 @@ */ package org.onap.aai.db.schema; -import org.codehaus.jackson.annotate.JsonProperty; - import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + public class AuditDoc { private List<DBProperty> properties; private List<DBIndex> indexes; private List<EdgeProperty> edgeLabels; - + /** * Gets the properties. * @@ -37,7 +37,7 @@ public class AuditDoc { public List<DBProperty> getProperties() { return properties; } - + /** * Sets the properties. * @@ -46,7 +46,7 @@ public class AuditDoc { public void setProperties(List<DBProperty> properties) { this.properties = properties; } - + /** * Gets the indexes. * @@ -55,7 +55,7 @@ public class AuditDoc { public List<DBIndex> getIndexes() { return indexes; } - + /** * Sets the indexes. * @@ -64,17 +64,17 @@ public class AuditDoc { public void setIndexes(List<DBIndex> indexes) { this.indexes = indexes; } - - /** - * Gets the edge labels. - * - * @return the edge labels - */ - @JsonProperty("edge-labels") + + /** + * Gets the edge labels. + * + * @return the edge labels + */ + @JsonProperty("edge-labels") public List<EdgeProperty> getEdgeLabels() { return edgeLabels; } - + /** * Sets the edge labels. * @@ -83,6 +83,4 @@ public class AuditDoc { public void setEdgeLabels(List<EdgeProperty> edgeLabels) { this.edgeLabels = edgeLabels; } - - } diff --git a/src/main/java/org/onap/aai/db/schema/EdgeProperty.java b/src/main/java/org/onap/aai/db/schema/EdgeProperty.java index f89bc8f..7b1dd4b 100644 --- a/src/main/java/org/onap/aai/db/schema/EdgeProperty.java +++ b/src/main/java/org/onap/aai/db/schema/EdgeProperty.java @@ -19,34 +19,35 @@ */ package org.onap.aai.db.schema; -import org.codehaus.jackson.annotate.JsonProperty; -import org.codehaus.jackson.annotate.JsonPropertyOrder; import org.janusgraph.core.Multiplicity; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; + @JsonPropertyOrder({ "label", "multiplicity" }) public class EdgeProperty implements Named { private String name = null; private Multiplicity multiplicity = null; - + /** * Gets the name */ - @JsonProperty("label") + @JsonProperty("label") public String getName() { return name; } - - /** - * Sets the name. - * - * @param name the new name - */ - @JsonProperty("label") + + /** + * Sets the name. + * + * @param name the new name + */ + @JsonProperty("label") public void setName(String name) { this.name = name; } - + /** * Gets the multiplicity. * @@ -55,7 +56,7 @@ public class EdgeProperty implements Named { public Multiplicity getMultiplicity() { return multiplicity; } - + /** * Sets the multiplicity. * @@ -64,5 +65,5 @@ public class EdgeProperty implements Named { public void setMultiplicity(Multiplicity multiplicity) { this.multiplicity = multiplicity; } - + } diff --git a/src/main/java/org/onap/aai/db/schema/ScriptDriver.java b/src/main/java/org/onap/aai/db/schema/ScriptDriver.java index 88c9bf9..073ca59 100644 --- a/src/main/java/org/onap/aai/db/schema/ScriptDriver.java +++ b/src/main/java/org/onap/aai/db/schema/ScriptDriver.java @@ -23,7 +23,6 @@ import com.beust.jcommander.JCommander; import com.beust.jcommander.Parameter; import com.fasterxml.jackson.databind.ObjectMapper; import org.apache.commons.configuration2.PropertiesConfiguration; -import org.codehaus.jackson.JsonGenerationException; import org.janusgraph.core.JanusGraph; import org.janusgraph.core.JanusGraphFactory; import org.onap.aai.restclient.PropertyPasswordConfiguration; diff --git a/src/main/java/org/onap/aai/web/JerseyConfiguration.java b/src/main/java/org/onap/aai/web/JerseyConfiguration.java index 7da90c0..99f304d 100644 --- a/src/main/java/org/onap/aai/web/JerseyConfiguration.java +++ b/src/main/java/org/onap/aai/web/JerseyConfiguration.java @@ -19,7 +19,6 @@ */ package org.onap.aai.web; -import com.sun.jersey.api.client.filter.LoggingFilter; import java.util.List; import java.util.Set; import java.util.logging.Logger; @@ -27,6 +26,7 @@ import java.util.stream.Collectors; import javax.annotation.Priority; import javax.ws.rs.container.ContainerRequestFilter; import javax.ws.rs.container.ContainerResponseFilter; +import org.glassfish.jersey.logging.LoggingFeature; import org.glassfish.jersey.server.ResourceConfig; import org.glassfish.jersey.servlet.ServletProperties; import org.onap.aai.rest.AuditSqlDbConsumer; @@ -65,7 +65,7 @@ public class JerseyConfiguration extends ResourceConfig { // Following registers the request headers and response headers // If the LoggingFilter second argument is set to true, it will print response value as well if ("true".equalsIgnoreCase(env.getProperty("aai.request.logging.enabled"))) { - register(new LoggingFilter(log, 0)); + register(new LoggingFeature(log)); } } |