-
Notifications
You must be signed in to change notification settings - Fork 99
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
Random org.apache.xerces.impl.dv.DVFactoryException with 2.0.13 and 2.0.14 #560
Comments
Thanks for the report. I'll take a look and keep you updated |
@tmortagne : is it public code (repository) that I could grab for analysis or not ? |
I think yes, so where could I see the build error on the CI ? Thanks |
@tmortagne : as far as I can tell for the moment :
|
Yes, but what is not clear to me is why. Maven plugins are supposed to run with their own classpath as far as I know (otherwise they would be extremely fragile, it's xercesImpl this time, but it could be pretty much anything which conflict with the plugin's dependencies for any reason). |
My first guess is that it comes from the xjcPlugins resolution process, which computes the dependencies (with transitivity) of the project + the plugins, and when xerces is in project dependency, it grabs it in the final classloader. I guess we could try to exclude it (xercesImpl and xml-apis which is taken from the previous one) from the process of the dependencies. |
…inal classpath of maven-plugin
That's what the log seems to suggest. But I guess my question would be more if this process is really needed at all for the |
Well, if Alexey was still here, we could ask him but I'm pretty sure there is a good reason behind this. I've done a PR to manually exclude I'll let @mattrpav review for merge and then I'll cherry-pick this one in 2.x branch so we could cut a 2.0.15 release 👍 |
Thanks for working on this. |
@tmortagne can you share the dependency tree out or display the classpath? |
You just mean the result of
|
…solution defaults to xercesImpl and xml-apis
I changed my commit to make it customizable and more importantly : switched off. |
…solution defaults to xercesImpl and xml-apis
Default now to |
We upgraded from 2.0.12, and we are getting random failures which suggest a messy classpath:
Here is a more complete context with the relevant verbose part of the Maven build log.
The
xjcPluginArtifacts
log is a bit surprising, it feels like it's loading all the dependencies of the module it's building in its classpath, and that's where Xerces is coming from I guess (this module indeed depends indirectly on Xerces). But I don't quite understand why it needs to load all that.with the following parent pom.xml setup
used for example with
I unfortunately don't have much to give you as simple reproduction project/steps since it's quite random on our CI (but we never got that with 2.0.12) and I was never able to reproduce locally.
On the CI,
java -version
gives:and it's using Maven 3.9.6.
The text was updated successfully, but these errors were encountered: