Jump to content
We've recently updated our Privacy Statement, available here ×

Cannot connect Studio Plugin to a JasperReports Server (JAXB-API issue?)


marc_d

Recommended Posts

Hello,

I am new to using the Jaspersoft Studio plugin with an Eclipse IDE.  I've gotten as far as installing Eclipse (4.18).  Adding in Studio from Marketplace (6.16.0), and even setting up a simple report in the JasperReport Perspective in Eclipse.  Where I am getting stuck is adding a Jaser Reports Server connection to the Repository.  I am sure I got the URL and credentials correct, but when I "Test Connection"  I get an HTTP 500 error.

Detail output includes:

 

javax.ws.rs.InternalServerErrorException: HTTP 500 Internal Server Error

...

Caused by: javax.xml.bind.JAXBException: Implementation of JAXB-API has not been found on module path or classpath.
 - with linked exception:
[java.lang.ClassNotFoundException: com.sun.xml.bind.v2.ContextFactory]

...

Caused by: java.lang.ClassNotFoundException: com.sun.xml.bind.v2.ContextFactory

 

Hunting around, this seems to have something to do with changes in Java 11, however, don't know how to work around this issue in Eclipse in order to make sure JAXB-API can be used and the communication to the Jasper Reports Server can be made.  Connection to the same server works in and older, stand-alone version of Studio, but I'd like to get things up-to-date and use the full Eclipse environment for this development.

 

Link to comment
Share on other sites

  • 5 months later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

JAXB-API was included as part of the core JAVA 8 language; it was deprecated in JAVA9/10 and removed from core in JAVA11.

There is a way to include JAXB-API as an optional-extra package, but it might be easier just to evade the issue by rolling your client machine back to JAVA8 as the default, ie (for Ubuntu 21.04, as an example):

sudo apt-get install openjdk-8-jre;

sudo update-alternatives --config java;

java -version;

Restart Eclipse and you should have the ability to connect Jasper's Eclipse plugin to a remote server.

See also https://community.jaspersoft.com/jaspersoft-studio/issues/13581

It's a kludge solution and it would be better if Jasper were to update the plugin to behave properly in Java11, but it will get you past this.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...