From 743d8e8ad497367be779f942165f2256c09432d0 Mon Sep 17 00:00:00 2001 From: Ehsan Sasanianno Date: Mon, 7 Aug 2023 22:39:31 +0200 Subject: [PATCH] java-20349: move pre-jpms module to core-java-9 module --- core-java-modules/core-java-9/README.md | 1 + core-java-modules/core-java-9/pom.xml | 9 ++ .../java/com/baeldung/java9}/prejpms/App.java | 5 +- .../com/baeldung/java9}/prejpms/Book.java | 2 +- core-java-modules/pom.xml | 1 - core-java-modules/pre-jpms/README.md | 3 - core-java-modules/pre-jpms/pom.xml | 86 ------------------- .../pre-jpms/src/main/resources/logback.xml | 10 --- 8 files changed, 14 insertions(+), 103 deletions(-) rename core-java-modules/{pre-jpms/src/main/java/com/baeldung => core-java-9/src/main/java/com/baeldung/java9}/prejpms/App.java (98%) rename core-java-modules/{pre-jpms/src/main/java/com/baeldung => core-java-9/src/main/java/com/baeldung/java9}/prejpms/Book.java (94%) delete mode 100644 core-java-modules/pre-jpms/README.md delete mode 100644 core-java-modules/pre-jpms/pom.xml delete mode 100644 core-java-modules/pre-jpms/src/main/resources/logback.xml diff --git a/core-java-modules/core-java-9/README.md b/core-java-modules/core-java-9/README.md index bd7df0c8a6..43f8bf8ca8 100644 --- a/core-java-modules/core-java-9/README.md +++ b/core-java-modules/core-java-9/README.md @@ -12,3 +12,4 @@ This module contains articles about Java 9 core features - [Private Methods in Java Interfaces](https://www.baeldung.com/java-interface-private-methods) - [Java Scanner useDelimiter with Examples](https://www.baeldung.com/java-scanner-usedelimiter) - [Is There a Destructor in Java?](https://www.baeldung.com/java-destructor) +- [Java 9 Migration Issues and Resolutions](https://www.baeldung.com/java-9-migration-issue) \ No newline at end of file diff --git a/core-java-modules/core-java-9/pom.xml b/core-java-modules/core-java-9/pom.xml index bcfdacdf1d..616dceb2bf 100644 --- a/core-java-modules/core-java-9/pom.xml +++ b/core-java-modules/core-java-9/pom.xml @@ -46,6 +46,11 @@ commons-io ${commons-io.version} + + javax.xml.bind + jaxb-api + ${javax.xml.bind.version} + @@ -58,6 +63,9 @@ ${maven.compiler.source} ${maven.compiler.target} + + --add-exports=java.base/com.sun.crypto.provider=ALL-UNNAMED + @@ -74,6 +82,7 @@ 1.7.0 1.9 1.9 + 2.4.0-b180725.0427 \ No newline at end of file diff --git a/core-java-modules/pre-jpms/src/main/java/com/baeldung/prejpms/App.java b/core-java-modules/core-java-9/src/main/java/com/baeldung/java9/prejpms/App.java similarity index 98% rename from core-java-modules/pre-jpms/src/main/java/com/baeldung/prejpms/App.java rename to core-java-modules/core-java-9/src/main/java/com/baeldung/java9/prejpms/App.java index a69e0555c6..d97ff4b743 100644 --- a/core-java-modules/pre-jpms/src/main/java/com/baeldung/prejpms/App.java +++ b/core-java-modules/core-java-9/src/main/java/com/baeldung/java9/prejpms/App.java @@ -1,15 +1,16 @@ -package com.baeldung.prejpms; +package com.baeldung.java9.prejpms; import java.io.StringWriter; import java.lang.StackWalker.Option; import java.lang.StackWalker.StackFrame; -import com.sun.crypto.provider.SunJCE; import java.util.Base64; import java.util.concurrent.atomic.AtomicInteger; import javax.xml.bind.JAXBContext; import javax.xml.bind.Marshaller; +import com.sun.crypto.provider.SunJCE; + import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/core-java-modules/pre-jpms/src/main/java/com/baeldung/prejpms/Book.java b/core-java-modules/core-java-9/src/main/java/com/baeldung/java9/prejpms/Book.java similarity index 94% rename from core-java-modules/pre-jpms/src/main/java/com/baeldung/prejpms/Book.java rename to core-java-modules/core-java-9/src/main/java/com/baeldung/java9/prejpms/Book.java index 6780c73738..f94096b722 100644 --- a/core-java-modules/pre-jpms/src/main/java/com/baeldung/prejpms/Book.java +++ b/core-java-modules/core-java-9/src/main/java/com/baeldung/java9/prejpms/Book.java @@ -1,4 +1,4 @@ -package com.baeldung.prejpms; +package com.baeldung.java9.prejpms; import javax.xml.bind.annotation.XmlAttribute; import javax.xml.bind.annotation.XmlElement; diff --git a/core-java-modules/pom.xml b/core-java-modules/pom.xml index bfa48893e9..e9bb86e500 100644 --- a/core-java-modules/pom.xml +++ b/core-java-modules/pom.xml @@ -143,7 +143,6 @@ core-java-regex core-java-regex-2 core-java-uuid - pre-jpms core-java-collections-maps-6 core-java-records diff --git a/core-java-modules/pre-jpms/README.md b/core-java-modules/pre-jpms/README.md deleted file mode 100644 index 8c9af82ba5..0000000000 --- a/core-java-modules/pre-jpms/README.md +++ /dev/null @@ -1,3 +0,0 @@ -## Relevant Articles - -- [Java 9 Migration Issues and Resolutions](https://www.baeldung.com/java-9-migration-issue) diff --git a/core-java-modules/pre-jpms/pom.xml b/core-java-modules/pre-jpms/pom.xml deleted file mode 100644 index 67bc913767..0000000000 --- a/core-java-modules/pre-jpms/pom.xml +++ /dev/null @@ -1,86 +0,0 @@ - - - 4.0.0 - pre-jpms - pre-jpms - jar - - - com.baeldung.core-java-modules - core-java-modules - 0.0.1-SNAPSHOT - - - - - javax.xml.bind - jaxb-api - 2.4.0-b180725.0427 - - - org.slf4j - slf4j-api - ${org.slf4j.version} - - - - - pre-jpms - - - org.apache.maven.plugins - maven-compiler-plugin - ${compiler.plugin.version} - - ${source.version} - ${target.version} - - --add-exports=java.base/com.sun.crypto.provider=ALL-UNNAMED - - - - - org.apache.maven.plugins - maven-dependency-plugin - ${dependency.plugin.version} - - - copy-dependencies - package - - copy-dependencies - - - - ${project.build.directory}/dependency-jars/ - - - - - - - org.apache.maven.plugins - maven-jar-plugin - - - - com.baeldung.prejpms.App - true - dependency-jars/ - - - - - - - - - 3.1.1 - 3.8.0 - 11 - 11 - - - \ No newline at end of file diff --git a/core-java-modules/pre-jpms/src/main/resources/logback.xml b/core-java-modules/pre-jpms/src/main/resources/logback.xml deleted file mode 100644 index 7c5914e58e..0000000000 --- a/core-java-modules/pre-jpms/src/main/resources/logback.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - [%level] %msg%n - - - - - - \ No newline at end of file