diff options
16 files changed, 60 insertions, 62 deletions
diff --git a/aai-traversal/pom.xml b/aai-traversal/pom.xml index b80e1bd..6eb2e3d 100644 --- a/aai-traversal/pom.xml +++ b/aai-traversal/pom.xml @@ -26,7 +26,7 @@ <parent> <groupId>org.onap.aai.traversal</groupId> <artifactId>traversal</artifactId> - <version>1.14.4-SNAPSHOT</version> + <version>1.14.5-SNAPSHOT</version> </parent> <groupId>org.onap.aai.traversal</groupId> <artifactId>aai-traversal</artifactId> @@ -58,8 +58,6 @@ <aai.build.directory>${project.build.directory}/${project.artifactId}-${project.version}-build/</aai.build.directory> <aai.docker.version>1.0.0</aai.docker.version> <aai.docker.namespace>onap</aai.docker.namespace> - <aai.base.image>alpine</aai.base.image> - <aai.base.image.version>1.13.4</aai.base.image.version> <!-- Nexus Proxy Properties and Snapshot Locations Ideally this can be overwritten at runtime per internal environment specific values at runtime --> @@ -94,8 +92,8 @@ <!-- versions --> <spring.boot.version>2.4.13</spring.boot.version> - <janusgraph.version>0.5.3</janusgraph.version> - <gremlin.version>3.4.13</gremlin.version> + <janusgraph.version>0.6.0</janusgraph.version> + <gremlin.version>3.5.1</gremlin.version> <spring-cloud.version>2020.0.2</spring-cloud.version> @@ -120,41 +118,6 @@ <build> <plugins> <plugin> - <groupId>org.codehaus.groovy.maven</groupId> - <artifactId>gmaven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <phase>pre-clean</phase> - </execution> - <execution> - <id>parse-base</id> - <phase>prepare-package</phase> - <goals> - <goal>execute</goal> - </goals> - <configuration> - <source> - def userAaiBaseImage = session.userProperties['aai.base.image']; - def userAaiCommonVersion = - session.userProperties['aai.base.image.version']; - if (userAaiCommonVersion != null) { - project.properties['aai.base.image.version'] = - userAaiCommonVersion; - } - if (userAaiBaseImage != null) { - project.properties['aai.base.image'] = userAaiBaseImage; - } - log.info 'Base image flavour: ' + - project.properties['aai.base.image']; - log.info 'Base image version: ' + - project.properties['aai.base.image.version']; - </source> - </configuration> - </execution> - </executions> - </plugin> - <plugin> <groupId>io.fabric8</groupId> <artifactId>docker-maven-plugin</artifactId> <configuration> @@ -411,16 +374,6 @@ </exclusions> </dependency> <dependency> - <groupId>commons-configuration</groupId> - <artifactId>commons-configuration</artifactId> - <exclusions> - <exclusion> - <groupId>org.apache.commons</groupId> - <artifactId>commons-lang3</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-lang3</artifactId> </dependency> @@ -459,6 +412,10 @@ <groupId>org.slf4j</groupId> <artifactId>slf4j-log4j12</artifactId> </exclusion> + <exclusion> + <groupId>org.hibernate</groupId> + <artifactId>hibernate-validator</artifactId> + </exclusion> </exclusions> </dependency> <dependency> diff --git a/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java b/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java index b382a16..db6076b 100644 --- a/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java +++ b/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java @@ -40,6 +40,8 @@ import org.slf4j.MDC; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; import org.springframework.boot.autoconfigure.jdbc.DataSourceTransactionManagerAutoConfiguration; import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration; @@ -49,8 +51,14 @@ import org.springframework.core.env.Profiles; import org.springframework.boot.autoconfigure.jms.JmsAutoConfiguration; @SpringBootApplication( - exclude = {DataSourceAutoConfiguration.class, - DataSourceTransactionManagerAutoConfiguration.class, HibernateJpaAutoConfiguration.class, JmsAutoConfiguration.class}) + exclude = { + DataSourceAutoConfiguration.class, + DataSourceTransactionManagerAutoConfiguration.class, + HibernateJpaAutoConfiguration.class, + JmsAutoConfiguration.class, + CassandraDataAutoConfiguration.class, + CassandraAutoConfiguration.class + }) // Component Scan provides a way to look for spring beans // It only searches beans in the following packages // Any method annotated with @Bean annotation or any class @@ -58,7 +66,7 @@ import org.springframework.boot.autoconfigure.jms.JmsAutoConfiguration; @ComponentScan( basePackages = {"org.onap.aai.config", "org.onap.aai.web", "org.onap.aai.setup", "org.onap.aai.tasks", "org.onap.aai.service", "org.onap.aai.rest", "org.onap.aai.aaf", - "org.onap.aai.aailog"}) + "org.onap.aai.aailog", "org.onap.aai.introspection", "org.onap.aai.rest.notification"}) public class TraversalApp { private static final Logger logger = LoggerFactory.getLogger(TraversalApp.class.getName()); diff --git a/aai-traversal/src/test/java/org/onap/aai/AAIGremlinQueryTest.java b/aai-traversal/src/test/java/org/onap/aai/AAIGremlinQueryTest.java index 652c2f3..0bac97e 100644 --- a/aai-traversal/src/test/java/org/onap/aai/AAIGremlinQueryTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/AAIGremlinQueryTest.java @@ -47,6 +47,9 @@ import org.onap.aai.util.AAIConfig; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.web.server.LocalServerPort; import org.springframework.context.annotation.Import; @@ -80,6 +83,7 @@ import com.jayway.jsonpath.JsonPath; classes = TraversalApp.class) @TestPropertySource(locations = "classpath:application-test.properties") @ContextConfiguration(initializers = PropertyPasswordConfiguration.class) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test @Import(TraversalTestConfiguration.class) public class AAIGremlinQueryTest { diff --git a/aai-traversal/src/test/java/org/onap/aai/AAISetup.java b/aai-traversal/src/test/java/org/onap/aai/AAISetup.java index 7849671..5e6fccc 100644 --- a/aai-traversal/src/test/java/org/onap/aai/AAISetup.java +++ b/aai-traversal/src/test/java/org/onap/aai/AAISetup.java @@ -40,6 +40,7 @@ import org.onap.aai.rest.dsl.DslQueryProcessor; import org.onap.aai.rest.dsl.V1DslQueryProcessor; import org.onap.aai.rest.dsl.V2DslQueryProcessor; import org.onap.aai.rest.dsl.v1.DslListener; +import org.onap.aai.rest.notification.NotificationService; import org.onap.aai.rest.search.GremlinServerSingleton; import org.onap.aai.serialization.db.EdgeSerializer; import org.onap.aai.setup.AAIConfigTranslator; @@ -57,7 +58,8 @@ import org.springframework.test.context.junit4.rules.SpringMethodRule; classes = {ConfigConfiguration.class, AAIConfigTranslator.class, EdgeIngestor.class, EdgeSerializer.class, NodeIngestor.class, SpringContextAware.class, IntrospectionConfig.class, RestBeanConfig.class, SearchConfiguration.class, XmlFormatTransformerConfiguration.class, - GremlinServerSingleton.class, V1DslQueryProcessor.class, V2DslQueryProcessor.class, DslListener.class, org.onap.aai.rest.dsl.v2.DslListener.class}) + GremlinServerSingleton.class, V1DslQueryProcessor.class, V2DslQueryProcessor.class, DslListener.class, org.onap.aai.rest.dsl.v2.DslListener.class, + LoaderFactory.class, NotificationService.class}) @TestPropertySource( properties = {"schema.uri.base.path = /aai", "schema.ingest.file = src/test/resources/application-test.properties"}) diff --git a/aai-traversal/src/test/java/org/onap/aai/QueryParameterTest.java b/aai-traversal/src/test/java/org/onap/aai/QueryParameterTest.java index 817ba28..4e6ce81 100644 --- a/aai-traversal/src/test/java/org/onap/aai/QueryParameterTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/QueryParameterTest.java @@ -36,6 +36,9 @@ import org.onap.aai.config.PropertyPasswordConfiguration; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.web.server.LocalServerPort; import org.springframework.context.annotation.Import; @@ -51,6 +54,7 @@ import org.springframework.web.client.RestTemplate; classes = TraversalApp.class) @TestPropertySource(locations = "classpath:application-test.properties") @ContextConfiguration(initializers = PropertyPasswordConfiguration.class) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test @Import(TraversalTestConfiguration.class) public class QueryParameterTest { diff --git a/aai-traversal/src/test/java/org/onap/aai/SubgraphPruneTest.java b/aai-traversal/src/test/java/org/onap/aai/SubgraphPruneTest.java index 4aefa85..d6d385f 100644 --- a/aai-traversal/src/test/java/org/onap/aai/SubgraphPruneTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/SubgraphPruneTest.java @@ -31,6 +31,9 @@ import org.junit.Test; import org.junit.runner.RunWith; import org.onap.aai.config.PropertyPasswordConfiguration; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.web.server.LocalServerPort; import org.springframework.context.annotation.Import; @@ -46,6 +49,7 @@ import org.springframework.web.client.RestTemplate; classes = TraversalApp.class) @TestPropertySource(locations = "classpath:application-test.properties") @ContextConfiguration(initializers = PropertyPasswordConfiguration.class) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test @Import(TraversalTestConfiguration.class) public class SubgraphPruneTest { diff --git a/aai-traversal/src/test/java/org/onap/aai/TraversalTestConfiguration.java b/aai-traversal/src/test/java/org/onap/aai/TraversalTestConfiguration.java index 4a03c03..8e2e823 100644 --- a/aai-traversal/src/test/java/org/onap/aai/TraversalTestConfiguration.java +++ b/aai-traversal/src/test/java/org/onap/aai/TraversalTestConfiguration.java @@ -33,6 +33,9 @@ import org.apache.http.ssl.SSLContextBuilder; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.TestConfiguration; import org.springframework.boot.web.client.RestTemplateBuilder; import org.springframework.context.annotation.Bean; @@ -46,6 +49,7 @@ import org.springframework.web.client.ResponseErrorHandler; import org.springframework.web.client.RestTemplate; @TestConfiguration +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test public class TraversalTestConfiguration { private static final Logger logger = LoggerFactory.getLogger(TraversalTestConfiguration.class); diff --git a/aai-traversal/src/test/java/org/onap/aai/rest/BadQueryFormatTest.java b/aai-traversal/src/test/java/org/onap/aai/rest/BadQueryFormatTest.java index 1efbce7..6580c74 100644 --- a/aai-traversal/src/test/java/org/onap/aai/rest/BadQueryFormatTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/rest/BadQueryFormatTest.java @@ -37,6 +37,9 @@ import org.onap.aai.TraversalApp; import org.onap.aai.TraversalTestConfiguration; import org.onap.aai.config.PropertyPasswordConfiguration; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.web.server.LocalServerPort; import org.springframework.context.annotation.Import; @@ -52,6 +55,7 @@ import org.springframework.web.client.RestTemplate; classes = TraversalApp.class) @TestPropertySource(locations = "classpath:application-test.properties") @ContextConfiguration(initializers = PropertyPasswordConfiguration.class) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test @Import(TraversalTestConfiguration.class) public class BadQueryFormatTest { diff --git a/aai-traversal/src/test/java/org/onap/aai/rest/ConfigurationTest.java b/aai-traversal/src/test/java/org/onap/aai/rest/ConfigurationTest.java index 0992519..a892522 100644 --- a/aai-traversal/src/test/java/org/onap/aai/rest/ConfigurationTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/rest/ConfigurationTest.java @@ -35,6 +35,9 @@ import org.onap.aai.config.SpringContextAware; import org.onap.aai.restclient.PropertyPasswordConfiguration; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.autoconfigure.actuate.metrics.AutoConfigureMetrics; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.context.annotation.Import; @@ -57,6 +60,7 @@ import io.prometheus.client.exporter.common.TextFormat; @SpringBootTest( webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT, classes = {SpringContextAware.class, TraversalApp.class}) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test public class ConfigurationTest extends AbstractSpringRestTest { @Autowired RestTemplate restTemplate; diff --git a/aai-traversal/src/test/java/org/onap/aai/rest/QueryConsumerTest.java b/aai-traversal/src/test/java/org/onap/aai/rest/QueryConsumerTest.java index a6da4fc..e75019a 100644 --- a/aai-traversal/src/test/java/org/onap/aai/rest/QueryConsumerTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/rest/QueryConsumerTest.java @@ -49,6 +49,9 @@ import org.onap.aai.exceptions.AAIException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.web.server.LocalServerPort; import org.springframework.context.annotation.Import; @@ -65,6 +68,7 @@ import org.springframework.web.client.RestTemplate; classes = TraversalApp.class) @TestPropertySource(locations = "classpath:application-test.properties") @ContextConfiguration(initializers = PropertyPasswordConfiguration.class) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test @Import({TraversalTestConfiguration.class, WebClientConfiguration.class}) public class QueryConsumerTest { diff --git a/aai-traversal/src/test/java/org/onap/aai/rest/history/AbstractSpringHistoryRestTest.java b/aai-traversal/src/test/java/org/onap/aai/rest/history/AbstractSpringHistoryRestTest.java index 5e397dd..9fdce03 100644 --- a/aai-traversal/src/test/java/org/onap/aai/rest/history/AbstractSpringHistoryRestTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/rest/history/AbstractSpringHistoryRestTest.java @@ -36,6 +36,9 @@ import org.onap.aai.exceptions.AAIException; import org.onap.aai.nodes.NodeIngestor; import org.onap.aai.util.AAIConfig; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration; +import org.springframework.boot.autoconfigure.data.cassandra.CassandraDataAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.web.server.LocalServerPort; import org.springframework.context.annotation.Import; @@ -55,6 +58,7 @@ import org.springframework.web.client.RestTemplate; locations = "classpath:application-test.properties", properties = {"history.enabled=true", "history.truncate.window.days = " + Integer.MAX_VALUE}) @ContextConfiguration(initializers = PropertyPasswordConfiguration.class) +@EnableAutoConfiguration(exclude={CassandraDataAutoConfiguration.class, CassandraAutoConfiguration.class}) // there is no running cassandra instance for the test @Import(TraversalTestConfiguration.class) public abstract class AbstractSpringHistoryRestTest { diff --git a/aai-traversal/src/test/java/org/onap/aai/rest/search/OnapQueryTest.java b/aai-traversal/src/test/java/org/onap/aai/rest/search/OnapQueryTest.java index 44264c1..32f9d76 100644 --- a/aai-traversal/src/test/java/org/onap/aai/rest/search/OnapQueryTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/rest/search/OnapQueryTest.java @@ -80,7 +80,7 @@ import org.springframework.test.context.junit4.rules.SpringMethodRule; @ContextConfiguration( classes = {ConfigConfiguration.class, AAIConfigTranslator.class, EdgeIngestor.class, EdgeSerializer.class, NodeIngestor.class, SpringContextAware.class, - SearchConfiguration.class, IntrospectionConfig.class}) + SearchConfiguration.class, IntrospectionConfig.class, LoaderFactory.class}) @TestPropertySource( properties = {"schema.uri.base.path = /aai", "schema.ingest.file = src/test/resources/application-onap-test.properties"}) diff --git a/aai-traversal/src/test/java/org/onap/aai/rest/search/QueryTest.java b/aai-traversal/src/test/java/org/onap/aai/rest/search/QueryTest.java index 4574ca1..2cbc1cd 100644 --- a/aai-traversal/src/test/java/org/onap/aai/rest/search/QueryTest.java +++ b/aai-traversal/src/test/java/org/onap/aai/rest/search/QueryTest.java @@ -59,6 +59,7 @@ import org.onap.aai.introspection.LoaderFactory; import org.onap.aai.introspection.ModelType; import org.onap.aai.nodes.NodeIngestor; import org.onap.aai.query.builder.GremlinTraversal; +import org.onap.aai.rest.notification.NotificationService; import org.onap.aai.restcore.search.GremlinGroovyShell; import org.onap.aai.restcore.search.GroovyQueryBuilder; import org.onap.aai.serialization.db.EdgeSerializer; @@ -80,7 +81,7 @@ import org.springframework.test.context.junit4.rules.SpringMethodRule; @ContextConfiguration( classes = {ConfigConfiguration.class, AAIConfigTranslator.class, EdgeIngestor.class, EdgeSerializer.class, NodeIngestor.class, SpringContextAware.class, - SearchConfiguration.class, IntrospectionConfig.class}) + SearchConfiguration.class, IntrospectionConfig.class, LoaderFactory.class, NotificationService.class}) @TestPropertySource( properties = {"schema.uri.base.path = /aai", "schema.ingest.file = src/test/resources/application-test.properties"}) @@ -26,11 +26,11 @@ <parent> <groupId>org.onap.aai.aai-common</groupId> <artifactId>aai-parent</artifactId> - <version>1.14.4</version> + <version>1.14.5</version> </parent> <groupId>org.onap.aai.traversal</groupId> <artifactId>traversal</artifactId> - <version>1.14.4-SNAPSHOT</version> + <version>1.14.5-SNAPSHOT</version> <name>aai-traversal</name> <packaging>pom</packaging> <modules> @@ -41,7 +41,7 @@ Nexus Proxy Properties and Snapshot Locations Ideally this can be overwritten at runtime per internal environment specific values at runtime --> - <aai.common.version>1.14.4</aai.common.version> + <aai.common.version>1.14.5</aai.common.version> <nexusproxy>https://nexus.onap.org</nexusproxy> <site.path>/content/sites/site/org/onap/aai/traversal/${project.artifactId}/${project.version}</site.path> <release.path>/content/repositories/releases/</release.path> diff --git a/test_csvWriter.csv b/test_csvWriter.csv deleted file mode 100644 index 2f66fec..0000000 --- a/test_csvWriter.csv +++ /dev/null @@ -1,2 +0,0 @@ -s0,s1 -t0,t1 diff --git a/version.properties b/version.properties index 82f9610..0f5234a 100644 --- a/version.properties +++ b/version.properties @@ -5,7 +5,7 @@ major_version=1 minor_version=14 -patch_version=4 +patch_version=5 base_version=${major_version}.${minor_version}.${patch_version} |