eclipse-ee4j / eclipse-ee4j/jersey

JAXBContext implementation could not be found

Open
#5,231 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
730
Forks
382
PR merge metrics
No merged PRs in 30d

Description

I am using jersey with the grizzly HTTP server and I am getting this error:
```
Jan 05, 2023 1:18:00 PM org.glassfish.jersey.server.wadl.WadlFeature configure
WARNING: JAXBContext implementation could not be found. WADL feature is disabled.
```
These are my dependencies:
```

org.glassfish.grizzly
grizzly-http-server
4.0.0

org.glassfish.jersey.containers
jersey-container-grizzly2-http
3.1.0

jakarta.ws.rs
jakarta.ws.rs-api
3.1.0

org.glassfish.jaxb
jaxb-core
4.0.1

org.glassfish.jersey.inject
jersey-hk2
3.1.0

```
[This](https://stackoverflow.com/questions/65444486/warning-jaxbcontext-implementation-could-not-be-found-wadl-feature-is-disabled) stack overflow answer was suggesting that I add `jaxb-runtime` as a dependency, but I already have `jaxb-core` and `jaxb-runtime` is part of `jaxb-core`. Just to be sure, I tried using `jaxb-runtime`, but it didn't help.

This is the code I use to start the grizzly web server:
```
ResourceConfig config = new ResourceConfig();
config.register(App.class);
HttpServer server = GrizzlyHttpServerFactory.createHttpServer(URI.create("http://localhost:8080/"), config);
try {
server.start();
} catch (IOException e) {
logger.error("Exception while starting the API server", e);
}
```
I know I can disable WADL and I'll do that as a temporary solution, but it would be nice to have WADL working.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.