Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update JAXB dependencies from javax to jakarta #553

Open
janosch24 opened this issue Dec 7, 2024 · 1 comment
Open

Update JAXB dependencies from javax to jakarta #553

janosch24 opened this issue Dec 7, 2024 · 1 comment

Comments

@janosch24
Copy link
Contributor

janosch24 commented Dec 7, 2024

Problem or use case

Incorporating EmbeddedHiveMQ into frameworks like Spring Boot 3 leads to clashes regarding the JAXB implementation for config file reading, as dependencies are generally managed by Spring Boot.
As a work-around, required dependencies must get downgraded manually in order to make EmbeddedHiveMQ work.
This in turn leads to clashes in conjunction with other state-of-the-art components.

Motivation

  • Java EE has been rebranded to Jakarta EE several years ago, relocating packages from javax.xml.bind to jakarta.xml.bind
  • No drawbacks expected on the stand-alone version of HiveMQ-CE , as all dependencies are packed into a shadowed jar
  • No manual downgrade of JAXB dependencies for Spring Boot 3
  • Possible drawbacks in OSGi frameworks easily resolvable on a per-bundle-basis

Possible drawbacks

  • Requirement to upgrade dependencies and possibly code to jakarta-style JAXB on other systems using EmbeddedHiveMQ

Preferred solution or suggestions

  • for dependency jaxb-api use package: jakarta.xml.bind:jakarta.xml.bind-api:4.0.2
  • for dependency jaxb-impl use package: org.glassfish.jaxb:jaxb-runtime:4.0.5
  • Refactoring of all import statement from javax.xml.bind to jakarta.xml.bind
@janosch24
Copy link
Contributor Author

Tested suggested solution locally, all tests passed.
Tested outcomings in current Spring Boot 3.4.0, works as expected, no downgrade of JAXB dependencies required anymore.
If desired and appropriate I can make a pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant