diff options
-rw-r--r-- | aai-resources/pom.xml | 2 | ||||
-rw-r--r-- | aai-resources/src/main/java/org/onap/aai/rest/LegacyMoxyConsumer.java | 11 | ||||
-rw-r--r-- | aai-resources/src/main/resources/application.properties | 2 | ||||
-rw-r--r-- | aai-resources/src/test/resources/application-test.properties | 2 | ||||
-rw-r--r-- | aai-resources/src/test/resources/logback.xml | 5 | ||||
-rw-r--r-- | pom.xml | 6 | ||||
-rw-r--r-- | version.properties | 2 |
7 files changed, 20 insertions, 10 deletions
diff --git a/aai-resources/pom.xml b/aai-resources/pom.xml index 8bc71c7..33828e4 100644 --- a/aai-resources/pom.xml +++ b/aai-resources/pom.xml @@ -28,7 +28,7 @@ <parent> <groupId>org.onap.aai.resources</groupId> <artifactId>resources</artifactId> - <version>1.13.1-SNAPSHOT</version> + <version>1.13.3</version> </parent> <properties> <java.version>1.8</java.version> diff --git a/aai-resources/src/main/java/org/onap/aai/rest/LegacyMoxyConsumer.java b/aai-resources/src/main/java/org/onap/aai/rest/LegacyMoxyConsumer.java index c685071..4912a00 100644 --- a/aai-resources/src/main/java/org/onap/aai/rest/LegacyMoxyConsumer.java +++ b/aai-resources/src/main/java/org/onap/aai/rest/LegacyMoxyConsumer.java @@ -290,9 +290,8 @@ public class LegacyMoxyConsumer extends RESTAPI { Introspector obj = loader.introspectorFromName(objType); DBRequest request = new DBRequest.Builder(HttpMethod.GET, uriObject, uriQuery, obj, headers, info, transId).build(); - List<DBRequest> requests = new ArrayList<>(); - requests.add(request); - if (resultIndex != null && !"-1".equals(resultIndex) && resultSize != null && !"-1".equals(resultSize)) { + List<DBRequest> requests = Collections.singletonList(request); + if (hasValidPaginationParams(resultIndex, resultSize)) { traversalUriHttpEntry.setPaginationIndex(Integer.parseInt(resultIndex)); traversalUriHttpEntry.setPaginationBucket(Integer.parseInt(resultSize)); } @@ -320,6 +319,10 @@ public class LegacyMoxyConsumer extends RESTAPI { return response; } + private boolean hasValidPaginationParams(String resultIndex, String resultSize) { + return resultIndex != null && !"-1".equals(resultIndex) && resultSize != null && !"-1".equals(resultSize); + } + private MultivaluedMap<String, String> removeNonFilterableParams(MultivaluedMap<String, String> params) { String[] toRemove = @@ -554,7 +557,7 @@ public class LegacyMoxyConsumer extends RESTAPI { .build(); List<DBRequest> requests = new ArrayList<>(); requests.add(request); - if (resultIndex != null && !"-1".equals(resultIndex) && resultSize != null && !"-1".equals(resultSize)) { + if (hasValidPaginationParams(resultIndex, resultSize)) { traversalUriHttpEntry.setPaginationIndex(Integer.parseInt(resultIndex)); traversalUriHttpEntry.setPaginationBucket(Integer.parseInt(resultSize)); } diff --git a/aai-resources/src/main/resources/application.properties b/aai-resources/src/main/resources/application.properties index 094c81c..0389406 100644 --- a/aai-resources/src/main/resources/application.properties +++ b/aai-resources/src/main/resources/application.properties @@ -7,6 +7,8 @@ info.build.version=1.1.0 spring.application.name=aai-resources spring.jersey.type=filter spring.main.allow-bean-definition-overriding=true + +spring.sleuth.enabled=true spring.zipkin.baseUrl=http://jaeger-collector.istio-system:9411 spring.sleuth.messaging.jms.enabled = false spring.sleuth.trace-id128=true diff --git a/aai-resources/src/test/resources/application-test.properties b/aai-resources/src/test/resources/application-test.properties index cdc528f..596bd23 100644 --- a/aai-resources/src/test/resources/application-test.properties +++ b/aai-resources/src/test/resources/application-test.properties @@ -11,6 +11,8 @@ server.servlet.context-path=/ spring.jersey.application-path=${schema.uri.base.path} +spring.sleuth.enabled=false + spring.autoconfigure.exclude=\ org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration,\ org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration,\ diff --git a/aai-resources/src/test/resources/logback.xml b/aai-resources/src/test/resources/logback.xml index 4504bce..8bb9e7c 100644 --- a/aai-resources/src/test/resources/logback.xml +++ b/aai-resources/src/test/resources/logback.xml @@ -223,11 +223,14 @@ <logger name="org.zookeeper" level="OFF" /> - <logger name="org.onap.aai" level="DEBUG" additivity="false"> + <logger name="org.onap.aai" level="INFO" additivity="false"> <appender-ref ref="asyncDEBUG" /> <appender-ref ref="asyncSANE" /> <appender-ref ref="STDOUT" /> </logger> + <logger name="org.onap.aai.dbgen" level="WARN" additivity="false"> + <appender-ref ref="STDOUT" /> + </logger> <logger name="org.onap.aai.aailog.logs.AaiScheduledTaskAuditLog" level="INFO"> <appender-ref ref="asyncAUDIT"/> </logger> @@ -26,11 +26,11 @@ <parent> <groupId>org.onap.aai.aai-common</groupId> <artifactId>aai-parent</artifactId> - <version>1.13.0</version> + <version>1.13.3</version> </parent> <groupId>org.onap.aai.resources</groupId> <artifactId>resources</artifactId> - <version>1.13.1-SNAPSHOT</version> + <version>1.13.3</version> <name>aai-resources</name> <packaging>pom</packaging> <modules> @@ -48,7 +48,7 @@ <staging.path>/content/repositories/staging/</staging.path> <!-- GMaven plugin uses this property to figure out the name of the docker tag --> <aai.project.version>${project.version}</aai.project.version> - <aai.common.version>1.13.1</aai.common.version> + <aai.common.version>1.13.3</aai.common.version> <aai.schema.service.version>1.12.3</aai.schema.service.version> </properties> <build> diff --git a/version.properties b/version.properties index 0c0fa8e..20248c5 100644 --- a/version.properties +++ b/version.properties @@ -5,7 +5,7 @@ major_version=1 minor_version=13 -patch_version=1 +patch_version=2 base_version=${major_version}.${minor_version}.${patch_version} |