From 6b2121e478a1912e314e845aeb86c53411230a29 Mon Sep 17 00:00:00 2001 From: Baule A <65255151+baulea@users.noreply.github.com> Date: Fri, 27 Oct 2023 21:19:33 +0200 Subject: [PATCH 1/2] consolidate maven plugins Move maven plugin versions and configuration to section in parent.pom. Upgrade maven plugin versions. Fix warnings during maven build regarding missing version for maven-compiler-plugin [WARNING] [WARNING] Some problems were encountered while building the effective model for org.jsmart:http-testing:jar:1.3.36-SNAPSHOT [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 50, column 21 [WARNING] [WARNING] Some problems were encountered while building the effective model for org.jsmart:kafka-testing:jar:1.3.36-SNAPSHOT [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 56, column 12 [WARNING] [WARNING] Some problems were encountered while building the effective model for org.jsmart:zerocode-tdd-jupiter:jar:1.3.36-SNAPSHOT [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 145, column 21 [WARNING] [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build. [WARNING] [WARNING] For this reason, future Maven versions might no longer support building such malformed projects. [WARNING] --- core/pom.xml | 15 ------ http-testing/pom.xml | 5 -- junit5-testing/pom.xml | 5 -- kafka-testing/pom.xml | 5 -- pom.xml | 101 +++++++++++++++++++++++++++++++++-------- 5 files changed, 81 insertions(+), 50 deletions(-) diff --git a/core/pom.xml b/core/pom.xml index de612cc51..8f0d66fb4 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -201,11 +201,6 @@ org.apache.maven.plugins maven-compiler-plugin - ${maven-compiler-plugin.version} - - ${java-compiler-source.version} - ${java-compiler-target.version} - @@ -218,20 +213,13 @@ - org.apache.maven.plugins maven-compiler-plugin - ${maven-compiler-plugin.version} - - ${java-compiler-source.version} - ${java-compiler-target.version} - org.apache.maven.plugins maven-source-plugin - 2.2.1 attach-sources @@ -244,7 +232,6 @@ org.apache.maven.plugins maven-javadoc-plugin - attach-javadocs @@ -257,7 +244,6 @@ org.apache.maven.plugins maven-gpg-plugin - 1.5 sign-artifacts @@ -283,7 +269,6 @@ org.apache.maven.plugins maven-release-plugin - 2.5 true false diff --git a/http-testing/pom.xml b/http-testing/pom.xml index 7e2b18472..f36788a06 100644 --- a/http-testing/pom.xml +++ b/http-testing/pom.xml @@ -50,15 +50,10 @@ org.apache.maven.plugins maven-compiler-plugin - - ${java.version} - ${java.version} - org.apache.maven.plugins maven-surefire-plugin - 2.19.1 org.jsmart.zerocode.testhelp.tests.MockServerTest diff --git a/junit5-testing/pom.xml b/junit5-testing/pom.xml index 03cbdcdeb..7fdc97a42 100644 --- a/junit5-testing/pom.xml +++ b/junit5-testing/pom.xml @@ -145,15 +145,10 @@ org.apache.maven.plugins maven-compiler-plugin - - ${java.version} - ${java.version} - org.apache.maven.plugins maven-surefire-plugin - 3.0.0-M3 diff --git a/kafka-testing/pom.xml b/kafka-testing/pom.xml index 0a15cbefb..3d34893d1 100644 --- a/kafka-testing/pom.xml +++ b/kafka-testing/pom.xml @@ -56,15 +56,10 @@ org.apache.maven.plugins maven-compiler-plugin - - ${java.version} - ${java.version} - org.apache.maven.plugins maven-surefire-plugin - 2.19.1 org.jsmart.zerocode.integration.tests.kafka.KafkaSuite diff --git a/pom.xml b/pom.xml index e19726b09..ad246b382 100644 --- a/pom.xml +++ b/pom.xml @@ -85,11 +85,19 @@ 3.3.1 2.6.2 2.8.2 + - 3.2 + 3.11.0 1.8 1.8 - 2.5.4 + 3.6.0 + 3.3.0 + 3.6.0 + 3.1.0 + 3.0.1 + 3.2.1 + 3.6.1 + false 3.13.0 @@ -281,24 +289,77 @@ + + + + + + org.apache.maven.plugins + maven-compiler-plugin + ${maven-compiler-plugin.version} + + ${java-compiler-source.version} + ${java-compiler-target.version} + + + + org.apache.maven.plugins + maven-assembly-plugin + ${maven-assembly-plugin.version} + + + org.apache.maven.plugins + maven-source-plugin + ${maven-source-plugin.version} + + + org.apache.maven.plugins + maven-javadoc-plugin + ${maven-javadoc-plugin.version} + + + org.apache.maven.plugins + maven-gpg-plugin + ${maven-gpg-plugin.version} + + + org.apache.maven.plugins + maven-release-plugin + ${maven-release-plugin.version} + + + org.apache.maven.plugins + maven-surefire-plugin + ${maven-surefire-plugin.version} + + + org.apache.maven.plugins + maven-dependency-plugin + ${maven-dependency-plugin.version} + + + + - + + org.apache.maven.plugins + maven-shade-plugin + + false + + + + package + + shade + + + + + + --> + + From 1633e740059effbdc7e6b8c913bf8f78749e2a97 Mon Sep 17 00:00:00 2001 From: Baule A <65255151+baulea@users.noreply.github.com> Date: Sun, 29 Oct 2023 15:24:49 +0100 Subject: [PATCH 2/2] upgrade multiple dependencies upgrade dependencies in pom.xml: - upgrade org.jukito:jukito from 1.4.1 to 1.5 - upgrade commons-io:commons-io:2.4 to 2.15.0 - upgrade com.aventstack:extentreports:4.0.9 to 5.0.9 - upgrade com.google.code.gson:gson:2.6.2 to 2.10.1 - upgrade com.google.protobuf:protobuf-java:3.13.0 to 3.24.4 with upgrade com.aventstack:extentreports:4.0.9 to 5.0.9 replace ExtentHtmlReporter with ExtentSparkReporter in ExtentReportsFactory.java change in core/pom.xml: - set test scope for org.jukito:jukito - remove unused dependency com.fasterxml.jackson.datatype:jackson-datatype-jdk8 - remove direct dependency ch.qos.logback:logback-core, because it is a direct dependency from ch.qos.logback:logback-classic - add direct dependency org.apache.httpcomponents:httpmime:4.5.12 change in kafka-testing/pom.xml: - remove com.google.protobuf:protobuf-java-util - remove dependency for com.github.os72:protoc-jar --- core/pom.xml | 15 +++++-------- .../domain/builders/ExtentReportsFactory.java | 21 ++++++++++--------- kafka-testing/pom.xml | 9 -------- pom.xml | 21 ++++++++++--------- 4 files changed, 27 insertions(+), 39 deletions(-) diff --git a/core/pom.xml b/core/pom.xml index 8f0d66fb4..3aa0f7158 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -50,7 +50,6 @@ 4.12 - 2.6.2 @@ -103,10 +102,6 @@ ch.qos.logback logback-classic - - ch.qos.logback - logback-core - org.jboss.resteasy @@ -127,6 +122,7 @@ org.jukito jukito + test com.google.inject @@ -152,10 +148,6 @@ com.fasterxml.jackson.core jackson-databind - - com.fasterxml.jackson.datatype - jackson-datatype-jdk8 - junit junit @@ -164,7 +156,10 @@ org.apache.httpcomponents httpclient - ${httpclient.version} + + + org.apache.httpcomponents + httpmime org.jsmart diff --git a/core/src/main/java/org/jsmart/zerocode/core/domain/builders/ExtentReportsFactory.java b/core/src/main/java/org/jsmart/zerocode/core/domain/builders/ExtentReportsFactory.java index 929e85092..434cf5590 100644 --- a/core/src/main/java/org/jsmart/zerocode/core/domain/builders/ExtentReportsFactory.java +++ b/core/src/main/java/org/jsmart/zerocode/core/domain/builders/ExtentReportsFactory.java @@ -1,7 +1,8 @@ package org.jsmart.zerocode.core.domain.builders; import com.aventstack.extentreports.ExtentReports; -import com.aventstack.extentreports.reporter.ExtentHtmlReporter; +import com.aventstack.extentreports.reporter.ExtentSparkReporter; + import java.util.HashMap; import java.util.Map; import java.util.Properties; @@ -14,14 +15,14 @@ public class ExtentReportsFactory { private static final org.slf4j.Logger LOGGER = getLogger(ExtentReportsFactory.class); - private static ExtentHtmlReporter extentHtmlReporter; + private static ExtentSparkReporter extentSparkReporter; private static ExtentReports extentReports; private static Map systemProperties = new HashMap<>(); public static ExtentReports createReportTheme(String reportFileName) { - ExtentHtmlReporter extentHtmlReporter = createExtentHtmlReporter(reportFileName); + ExtentSparkReporter extentHtmlReporter = createExtentHtmlReporter(reportFileName); extentReports = new ExtentReports(); @@ -52,14 +53,14 @@ public static void attachSystemInfo() { extentReports.setSystemInfo("Java Vendor : ", javaVendor); } - public static ExtentHtmlReporter createExtentHtmlReporter(String reportFileName) { - extentHtmlReporter = new ExtentHtmlReporter(reportFileName); + public static ExtentSparkReporter createExtentHtmlReporter(String reportFileName) { + extentSparkReporter = new ExtentSparkReporter(reportFileName); - extentHtmlReporter.config().setDocumentTitle(REPORT_TITLE_DEFAULT); - extentHtmlReporter.config().setReportName(REPORT_DISPLAY_NAME_DEFAULT); + extentSparkReporter.config().setDocumentTitle(REPORT_TITLE_DEFAULT); + extentSparkReporter.config().setReportName(REPORT_DISPLAY_NAME_DEFAULT); - return extentHtmlReporter; + return extentSparkReporter; } @@ -88,11 +89,11 @@ public static Map getSystemProperties() { } public static void reportName(String reportName) { - extentHtmlReporter.config().setReportName(reportName); + extentSparkReporter.config().setReportName(reportName); } public static String getReportName() { - return extentHtmlReporter.config().getReportName(); + return extentSparkReporter.config().getReportName(); } } diff --git a/kafka-testing/pom.xml b/kafka-testing/pom.xml index 3d34893d1..db278f9fe 100644 --- a/kafka-testing/pom.xml +++ b/kafka-testing/pom.xml @@ -31,10 +31,6 @@ com.google.protobuf protobuf-java - - com.google.protobuf - protobuf-java-util - org.apache.kafka kafka-clients @@ -44,11 +40,6 @@ kafka-avro-serializer 5.1.0 - - com.github.os72 - protoc-jar - 3.11.4 - diff --git a/pom.xml b/pom.xml index ad246b382..ec48bdc66 100644 --- a/pom.xml +++ b/pom.xml @@ -68,7 +68,7 @@ 23.0 1.5.0 1.0 - 1.4.1 + 1.5 4.0 2.6 2.2.0 @@ -77,13 +77,14 @@ 2.19.0 1.7 2.9.8 - 2.4 + 2.15.0 1.1.10 4.5 + 4.5.12 1.4.191 - 4.0.9 + 5.0.9 3.3.1 - 2.6.2 + 2.10.1 2.8.2 @@ -100,7 +101,7 @@ false - 3.13.0 + 3.24.4 1.1.8.4 @@ -176,11 +177,6 @@ logback-classic ${logback.version} - - ch.qos.logback - logback-core - ${logback.version} - org.jboss.resteasy @@ -253,6 +249,11 @@ httpclient ${httpclient.version} + + org.apache.httpcomponents + httpmime + ${httpmime.version} + org.jsmart micro-simulator