From 9c71311e6a80d71e46f65ee4c989373d1831925b Mon Sep 17 00:00:00 2001 From: Bogdan Sava Date: Mon, 15 Nov 2021 21:36:11 +0200 Subject: [PATCH 1/6] fix hibernate-validator dependency Signed-off-by: Bogdan Sava --- .../graph-repository-connector/pom.xml | 10 +++++++++- .../server-chassis/server-chassis-spring/pom.xml | 8 ++++++++ pom.xml | 6 ++++++ 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/open-metadata-implementation/adapters/open-connectors/repository-services-connectors/open-metadata-collection-store-connectors/graph-repository-connector/pom.xml b/open-metadata-implementation/adapters/open-connectors/repository-services-connectors/open-metadata-collection-store-connectors/graph-repository-connector/pom.xml index e6b43657d6c..f6273084c65 100644 --- a/open-metadata-implementation/adapters/open-connectors/repository-services-connectors/open-metadata-collection-store-connectors/graph-repository-connector/pom.xml +++ b/open-metadata-implementation/adapters/open-connectors/repository-services-connectors/open-metadata-collection-store-connectors/graph-repository-connector/pom.xml @@ -131,6 +131,11 @@ snappy-java + + org.hibernate + hibernate-validator + + @@ -155,7 +160,10 @@ org.janusgraph:janusgraph-cql:* - joda-time:joda-time:* + joda-time:joda-time:* + + org.hibernate.validator:hibernate-validator:* + org.antlr:antlr-runtime:jar:* org.xerial.snappy:snappy-java:* diff --git a/open-metadata-implementation/server-chassis/server-chassis-spring/pom.xml b/open-metadata-implementation/server-chassis/server-chassis-spring/pom.xml index 7c8c2a2b670..603c89347a8 100644 --- a/open-metadata-implementation/server-chassis/server-chassis-spring/pom.xml +++ b/open-metadata-implementation/server-chassis/server-chassis-spring/pom.xml @@ -408,6 +408,11 @@ spring-boot-starter-web + + org.springframework.boot + spring-boot-starter-validation + + ch.qos.logback logback-classic @@ -496,6 +501,9 @@ org.springframework.boot:spring-boot-starter-web:* + org.springframework.boot:spring-boot-starter-validation:* + + org.springframework.boot:spring-boot-starter-security:* diff --git a/pom.xml b/pom.xml index 52311be1f67..ebcf870008a 100644 --- a/pom.xml +++ b/pom.xml @@ -2782,6 +2782,12 @@ ${spring-boot.version} + + org.springframework.boot + spring-boot-starter-validation + ${spring-boot.version} + + org.springframework.boot spring-boot-starter-test From 3578b55a156b741210c8ef23988e7d34332d6f37 Mon Sep 17 00:00:00 2001 From: Bogdan Sava Date: Mon, 15 Nov 2021 21:36:55 +0200 Subject: [PATCH 2/6] fix redundant spring-boot annotations Signed-off-by: Bogdan Sava --- .../serverchassis/springboot/OMAGServerPlatform.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java b/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java index 21198c73d58..28f3da25fd0 100644 --- a/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java +++ b/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java @@ -17,6 +17,7 @@ import org.springframework.beans.factory.annotation.Value; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; import org.springframework.context.ApplicationEventPublisher; import org.springframework.context.ApplicationListener; import org.springframework.context.annotation.Bean; @@ -32,8 +33,9 @@ import java.util.*; -@SpringBootApplication -@ComponentScan(basePackages = {"${scan.packages}"}) +@SpringBootApplication( + scanBasePackages = {"${scan.packages}"} +) @OpenAPIDefinition( info = @Info( title = "Egeria's Open Metadata and Governance (OMAG) Server Platform", From 65c563c9ff8022c704e85df3083e5fbe81273132 Mon Sep 17 00:00:00 2001 From: Bogdan Sava Date: Mon, 15 Nov 2021 21:37:30 +0200 Subject: [PATCH 3/6] remove unused imports Signed-off-by: Bogdan Sava --- .../serverchassis/springboot/OMAGServerPlatform.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java b/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java index 28f3da25fd0..929fa5c7e8f 100644 --- a/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java +++ b/open-metadata-implementation/server-chassis/server-chassis-spring/src/main/java/org/odpi/openmetadata/serverchassis/springboot/OMAGServerPlatform.java @@ -17,11 +17,9 @@ import org.springframework.beans.factory.annotation.Value; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; -import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; import org.springframework.context.ApplicationEventPublisher; import org.springframework.context.ApplicationListener; import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; import org.springframework.context.event.ContextClosedEvent; import org.springframework.context.event.ContextRefreshedEvent; From dbbb5f8a85739c315a92f7baab15323a9236131d Mon Sep 17 00:00:00 2001 From: Bogdan Sava Date: Mon, 15 Nov 2021 21:40:20 +0200 Subject: [PATCH 4/6] remove unnecessary scan exception Signed-off-by: Bogdan Sava --- .../user-interfaces/ui-chassis/ui-chassis-spring/pom.xml | 6 +++++- .../uichassis/springboot/EgeriaUIPlatform.java | 3 +-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/pom.xml b/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/pom.xml index 95796b81893..257aa943b3b 100644 --- a/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/pom.xml +++ b/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/pom.xml @@ -36,6 +36,11 @@ spring-boot-starter-web + + org.springframework.boot + spring-boot-starter-validation + + org.springframework.boot spring-boot-starter-security @@ -369,7 +374,6 @@ org.odpi.egeria:*spring* javax.xml.bind:*jaxb* org.springframework.boot:*:* - org.springframework.cloud:*:* org.apache.tomcat.embed:tomcat-embed-core:* diff --git a/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/src/main/java/org/odpi/openmetadata/userinterface/uichassis/springboot/EgeriaUIPlatform.java b/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/src/main/java/org/odpi/openmetadata/userinterface/uichassis/springboot/EgeriaUIPlatform.java index e6490b475bb..a4135090ae5 100644 --- a/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/src/main/java/org/odpi/openmetadata/userinterface/uichassis/springboot/EgeriaUIPlatform.java +++ b/open-metadata-implementation/user-interfaces/ui-chassis/ui-chassis-spring/src/main/java/org/odpi/openmetadata/userinterface/uichassis/springboot/EgeriaUIPlatform.java @@ -26,8 +26,7 @@ import javax.annotation.PostConstruct; @SpringBootApplication( - scanBasePackages = {"${scan.packages}"}, - exclude={DataSourceAutoConfiguration.class} + scanBasePackages = {"${scan.packages}"} ) @EnableConfigurationProperties( { From 4d8c5e973622ff02b0bcaf87b26f3f3c343aa7d4 Mon Sep 17 00:00:00 2001 From: Bogdan Sava Date: Mon, 15 Nov 2021 23:58:50 +0200 Subject: [PATCH 5/6] downgrade hibernate-validator Signed-off-by: Bogdan Sava --- .../open-metadata-fvt/access-services-fvt/pom.xml | 7 ------- pom.xml | 2 +- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/open-metadata-test/open-metadata-fvt/access-services-fvt/pom.xml b/open-metadata-test/open-metadata-fvt/access-services-fvt/pom.xml index 583fa9f4803..3e45394348f 100644 --- a/open-metadata-test/open-metadata-fvt/access-services-fvt/pom.xml +++ b/open-metadata-test/open-metadata-fvt/access-services-fvt/pom.xml @@ -27,13 +27,6 @@ access-services-fvt - - - org.odpi.egeria - graph-repository-connector - - - 2.10.1 3.3.1 From d41a84a1303a8aca6bf48c4be15d15903a4d57d0 Mon Sep 17 00:00:00 2001 From: Bogdan Sava Date: Thu, 18 Nov 2021 10:46:06 +0200 Subject: [PATCH 6/6] downgrade hibernate-validator Signed-off-by: Bogdan Sava --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index ddc5fb62dd5..39e1abfd912 100644 --- a/build.gradle +++ b/build.gradle @@ -202,7 +202,7 @@ allprojects { implementation("javax.servlet:javax.servlet-api:4.0.1") implementation("commons-configuration:commons-configuration:1.10") implementation("org.apache.commons:commons-configuration2:2.7") - implementation("org.hibernate:hibernate-validator:7.0.1.Final") + implementation("org.hibernate:hibernate-validator:6.2.0.Final") // testng also used in our 'source' code to support unit tests implementation("org.testng:testng:7.4.0")