Some problems were encountered while building the effective model for eu. For this reason, future Maven versions might no longer support building such malformed projects.
MR2:compile, com. MR1:compile, org. ClasspathCatalogResolver generatePackage:eu. Cannot find CatalogManager. Re-run Maven using the -X switch to enable full debug logging. The option to remove previous output was for a bug workaround; all it does is make sure everything's cleaned up first so recompilation is forced. So far so good. That project compiles without a hitch.
It should be noted that apart from the generated Java classes, I also package the schemas into the resulting jar file. So those are available on the classpath! The sun-jaxb. Then I start on the project that uses schemas which will extend the above, by first importing it. One of the "subtypes" could look like this I'll call it sub. Originally, all the schemas were in a single folder and I had the schemaLocation attribute in the import set to general.
But now that things are separated across projects, I run into problems. The first issue was that the other schema could not be found. Its contents are:. This seems to work, since I no longer get an error that states the schema cannot be found. But for some reason, resolving the actual type definitions from the imported schema continues to fail. Here's the exception:. Looking around online, it seems people have been running into this issue since at least and it might be related to some Xerces resolver problems.
I hope that this is not some bug that's been lurking around for 6 years without anyone caring to fix it. Does someone else have some suggestions? Maybe someone ran into the same problem and found a solution? The only workaround I can think of is to use 'svn:externals' to drag the general schema into the sub project and just regenerate the classes there, but it's dirty and will only work when you can connect to our svn repo.
Much thanks in advance for reading this long post. Do keep in mind that I've taken all of the above from existing projects and replaced some namespaces and other things for anonymity, so some typos are possible. This answer was edited. Have a project B depending on this, using the episode of A in B. In both cases I got the same exception as you. But I started to realize in situation 2 what is happening.
This is the exception: com. Exception: java. MalformedURLException: no! I traced the problem back to com. The solution I use is adapting the org.
This actually fixed my problem. I'll investigate a bit more. Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Collectives on Stack Overflow. Learn more. Asked 8 years, 5 months ago. Active 7 years, 3 months ago.
Viewed 7k times. Where I run into problems is trying to compile the project civic. Location []. Does anyone know why this might be happening? Thank you. Improve this question. Jan Tacci. Jan Tacci Jan Tacci 3, 16 16 gold badges 57 57 silver badges 83 83 bronze badges.
Add a comment. Active Oldest Votes. Author of the maven-jaxb2-plugin here. The catalog rewrites this URL into the systemId maven:org. This systemId is then resolved my the Maven catalog resolver delivered my the maven-jaxb2-plugin into the "real" URL which will be some jar So the schema is not downloaded from the Internet but taken from the local resource.
The workaround keep the "original" systemIds, therefor you can customize the schema using its original URL. The resolved systemId won't be convenient. The catalog file and the global bindings file will be the same for all the individual projects, so they're also put into the central artifact and referenced there using the dependencyResource.
Improve this answer. You need to do the following: Remove the 'catalogResolver' element from the plugin configuration in the poms.
RogierE RogierE 16 1 1 bronze badge. I will try it but one thing
0コメント