From: sebdet Date: Tue, 11 Dec 2018 11:39:11 +0000 (+0100) Subject: Fix concurrent build X-Git-Tag: 6.0.0~11^2~602 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=a664994195fe5af803c2d9ceb0a8b79bca21d426;p=policy%2Fclamp.git Fix concurrent build Fix concurrent build issue that may occur and generate random ports automatically in the build Issue-ID: CLAMP-252 Change-Id: If1b67a3a03fea52971b494621a4ba3ba44ee6a01 Signed-off-by: sebdet --- diff --git a/pom.xml b/pom.xml index 124bee438..8e7f6aabb 100644 --- a/pom.xml +++ b/pom.xml @@ -60,13 +60,11 @@ UTF-8 UTF-8 - 3306 - 8085 git-server 1.8 1.0.0 - 2.22.0 + 2.22.1 2.0.6.RELEASE jacoco @@ -671,6 +669,35 @@ + + org.sonatype.plugins + port-allocator-maven-plugin + 1.2 + + + validate + + allocate-ports + + + + + docker.mariadb.port.host + + + docker.http-cache.port.host + + + clamp.it.tests.https + + + clamp.it.tests.http + + + + + + diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 28779af5b..ef4c4fcb4 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -99,7 +99,7 @@ camel.springboot.xmlRests=classpath:/clds/camel/rest/*.xml #clds datasource connection details spring.datasource.cldsdb.driverClassName=org.mariadb.jdbc.Driver -spring.datasource.cldsdb.url=jdbc:mariadb:sequential://localhost:${docker.mariadb.port.host}/cldsdb4?autoReconnect=true&connectTimeout=10000&socketTimeout=10000&retriesAllDown=3 +spring.datasource.cldsdb.url=jdbc:mariadb:sequential://localhost:3306/cldsdb4?autoReconnect=true&connectTimeout=10000&socketTimeout=10000&retriesAllDown=3 spring.datasource.cldsdb.username=clds spring.datasource.cldsdb.password=4c90a0b48204383f4283448d23e0b885a47237b2a23588e7c4651604f51c1067 spring.datasource.cldsdb.validationQuery=SELECT 1 diff --git a/src/test/resources/application.properties b/src/test/resources/application.properties index 8d6cd384e..7116940f8 100644 --- a/src/test/resources/application.properties +++ b/src/test/resources/application.properties @@ -30,7 +30,7 @@ info.build.version=@project.version@ ### (See below for the parameter 'server.http.port' if you want to have both enabled) ### To have only HTTP, keep the lines server.ssl.* commented ### To have only HTTPS enabled, uncomment the server.ssl.* lines and specify a right keystore location -server.port=8080 +server.port=${clamp.it.tests.http} ### Settings for HTTPS (this automatically enables the HTTPS on the port 'server.port') #server.ssl.key-store=file:/tmp/mykey.jks #server.ssl.key-store-password=pass diff --git a/src/test/resources/https/https-test.properties b/src/test/resources/https/https-test.properties index e15ea6edc..34b7222e4 100644 --- a/src/test/resources/https/https-test.properties +++ b/src/test/resources/https/https-test.properties @@ -25,7 +25,7 @@ ### (See below for the parameter 'server.http.port' if you want to have both enabled) ### To have only HTTP, keep the lines server.ssl.* commented ### To have only HTTPS enabled, uncomment the server.ssl.* lines and specify a right keystore location -server.port=10443 +server.port=${clamp.it.tests.https} ### Settings for HTTPS (this automatically enables the HTTPS on the port 'server.port') server.ssl.key-store=classpath:https/keystore-test.jks server.ssl.key-store-password=testpass