👉 Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException
🔎 info) JAXB is a Java API that displays Java classes in XML.
☔ Cause of error
👉 You cannot use the JAXB API in Java 9 and later versions, as it has been removed (deprecated).
🧙 Solution
👉 Please write the code below in pom.xml
<dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>2.3.0</version>
</dependency>
👉 If you are using Gradle, please write the code below.
implementation 'javax.xml.bind:jaxb-api:2.3.0'
Did my writing help you?
Please press the thumb-up button
If you have any questions, please leave them in the comments