geoserver icon indicating copy to clipboard operation
geoserver copied to clipboard

Remove dependency on xml-apis-xerces on the printing extension

Open groldan opened this issue 1 year ago • 8 comments

xml-apis:xml-apis-xerces:2.7.1 is the same as xml-apis:xml-apis but from 2012 and unnecessary since Java 1.6.

Checklist

For core and extension modules:

  • [ ] New unit tests have been added covering the changes.
  • [ ] Documentation has been updated (if change is visible to end users).
  • [ ] The REST API docs have been updated (when changing configuration objects or the REST controllers).
  • [ ] There is an issue in the GeoServer Jira (except for changes that do not affect administrators or end users in any way).
  • [ ] Commit message(s) must be in the form [GEOS-XYZWV] Title of the Jira ticket.
  • [ ] Bug fixes and small new features are presented as a single commit.
  • [ ] Each commit has a single objective (if there are multiple commits, each has a separate JIRA ticket describing its goal).

groldan avatar Aug 06 '24 16:08 groldan

@jodygarnett I'd feel better if you could have a look at this one.

aaime avatar Aug 08 '24 17:08 aaime

Understood

jodygarnett avatar Aug 08 '24 18:08 jodygarnett

@groldan how does the interact with mapfish-print-v2 release?

jodygarnett avatar Aug 08 '24 19:08 jodygarnett

@jodygarnett your question made me realize I didn't remove the <include>xml-apis-xerces-*.jar</include> include from src/release/ext-printing.xml. Just did.

That said, I'm not sure I understand your question. The xml-apis dependency is not necessary since Java 1.6. The xml-apis-xerces dependency contains exactly the same classes as xml-apis:xml-apis. xml-apis-xerces is just released a year before xml-apis:xml-apis, and they don't even include the StAX apis. So they're just ancient and all their classes have been included in the standard JRE system library for a long time (javax.xml, org.s3c.dom, and org.xml.sax namespaces).

groldan avatar Aug 11 '24 15:08 groldan

Thanks I was trying to ask if any similar change is useful for mapfish-print-v2 (since as you say xerces dependency not useful). Is any dependency changes needed there, or do any dependency excludes need to be added …

jodygarnett avatar Aug 11 '24 18:08 jodygarnett

@groldan @jodygarnett I don't understand if this should be closed and moved upstream to mapfish-print-v2, or merged here...

aaime avatar Oct 07 '24 09:10 aaime

@groldan can I remove xerces dependency from mapfish print?

jodygarnett avatar Oct 08 '24 02:10 jodygarnett

@jodygarnett you definitely can remove the xml-apis-xerces dependency from mapfishprint, I'm guessing it's at least on Java 8, and the apis are part of the standard lib since 1.6.

Since this PR is about removing the dependency explicitly declared in the printing extension's pom, this pr should be merged regardless.

groldan avatar Oct 11 '24 12:10 groldan

Let's go then

aaime avatar Dec 02 '24 11:12 aaime