Issue
Materialised fully functional Spring Boot application code from repository and working fine with java 1.8. While upgrading to Java 11 got errors like some packages is accessible from more than one module
1.The package javax.xml.parsers is accessible from more than one module: <unnamed>, java.xml
2.The package org.xml.sax is accessible from more than one module: <unnamed>, java.xml
Tried to resolve the issue by restrict dependency using methods provided in the below links but not helped.
Archiva dependency integrated to Spring Boot as rootParent
Error While upgrading to java 11
Build path of migrated project
Solution
Reason : Conflict between xml.apis
and java.xml
.due to the modularity concept in java
Solution : Excluded xml.apis
dependency in maven pom file.
Answered By - Rinu
Answer Checked By - Candace Johnson (JavaFixing Volunteer)