averbraeck / opentrafficsim

Open Source Multi-Level Traffic Simulator
BSD 3-Clause "New" or "Revised" License
29 stars 11 forks source link

Check if jaxb version 2.3.1 can be replaced by jakarta.xml.bind-api #148

Open averbraeck opened 2 weeks ago

averbraeck commented 2 weeks ago

In the mvnrepository, it is indicated that the jaxb-api is succeeded by the Jakarta XML Binding API. We have to see if this works in the ots-parser-xml project and what the side effects are.

The jaxb-api is not updated since 2018, where the Jakarta XML Binding API has regular releases; the latest being from March 2024.

averbraeck commented 2 weeks ago

The jaxb-api also still uses javax.annotation-api that has been replaced by jakarta.annotation-api. Therefore, the POM file n ots-parser-xml has a dependency:

    <dependency>
      <groupId>javax.annotation</groupId>
      <artifactId>javax.annotation-api</artifactId>
      <version>1.3.2</version>
    </dependency>

whereas jakarta.annotation-api version 3.0.0 (a much later version) is already included in the entire OTS project.

averbraeck commented 2 weeks ago

A first check shows that updating JAXB is not straightforward. We might have to do some smaller tests first to see how to integrate JAXB itself, the maven-jaxb2 plugins, the org.glassfish.jaxb/jaxb-runtime library, and the org.jvnet.jaxb2.maven2/maven-jaxb2-plugin that are now all interacting in a way that defies partial upgrades of one of the tools.