Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse Mars : The configured runtime is insufficient to provide an implementation for JAXB2.2

Eclipse version : Mars. JDK 1.8.

I want to create a JAXB project. In the JAXB Facet page, there is the following error:

The configured runtime is insufficient to provide an implementation for JAXB2.2

Could you give me some suggestions on how I can fix it?

like image 728
Tianyu Zhu Avatar asked Sep 17 '15 20:09

Tianyu Zhu


4 Answers

I solved it like this (Eclipse Oxygen with jdk8):

  1. File/New/Project/JAXB/JAXB Project
  2. Next
  3. Give the name of the project
  4. Target Runtime: jdk8
  5. JAXB version: 2.2
  6. Next, Next
  7. Platform: Generic JAXB 2.2.
  8. JAXB Implementation Type: Disable Library Configuration.
  9. Finish.

This works.

like image 63
Marcelo P. Llanos C. Avatar answered Nov 04 '22 12:11

Marcelo P. Llanos C.


Here is what that worked for me (Eclipse Luna Service Release 2 (4.4.2)). In the third screen "JaxB Facet", in the JaxB Project wizard, select "User Library" as JaxB Implementation. Then click on "Manage Libraries" to create a new library with rt.jar from jdk/jre/lib folder. Now there is no error message, and the "Finish" button in the wizard is now active !

like image 33
user1158831 Avatar answered Sep 21 '22 20:09

user1158831


I faced the same problem. Below fix worked for me.

     1) Select File->New ->Project
     2) Choose JAXB Project from JAXB and click Next
     3) Give Project Name and click Next
     4) On the next window, just Click Next
     5) On the next window (titled JAXB Facets), Choose "User Library" for JAXB implementation. 
        Click "Download Library.." picture and choose EclipseLink 2.5.2 
        (or the higher version shown in the window) and click Next
        This will install the library (make sure your are connected to internet.)
like image 28
josepainumkal Avatar answered Nov 04 '22 12:11

josepainumkal


This is an issue with JDK8 in Eclipse, when you try creating a Generic JAXB2.2 project.

For fixing the issue in Eclipse Mars, do the following: While creating the project, select your Target Runtime as JDK7 and that will fix it. I have tried it myself, and it has worked fine!

If you want to continue to use JDK8, in the last screen of project creation, in JAXB implementation type, select "Disable Library Configuration" instead of JRE. This will remove the error and let you create the project. But I would suggest don't go for this as this may introduce more error in the future.

To use JDK8 in Eclipse Luna, a patch has been published to fix this issue. You can check it here: configure Generic JAXB 2.2 Platform with Java 1.8. I haven't tried it myself, but from the comments it seems the issue is resolved.

like image 7
kajarigd Avatar answered Nov 04 '22 14:11

kajarigd