Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
Java-SCA-2.0-Beta3
-
None
-
All
Description
There is code in WSDLModelResolver.resolveImports()
if (unresolved.getNamespace().equals(resolved.getDefinition().getTargetNamespace())) {
resolved.setNamespace(resolved.getDefinition().getTargetNamespace());
resolved.setUnresolved(false);
resolved.setURI(resolved.getLocation());
return modelClass.cast(resolved);
That puts the absolute location in the (usually relative) URI field. This was causing me some confusion when debugging another issue as the imported WSDL definition was constructed differently form the top level WSDL definition. I don't know whether the imported WSDL absolutely must have this URI file set to the location or whether it's just that the contribution relative URI is not readily available in the part of the code.
As an aside, while looking that this, I notices that in WSDLModelResolver.loadDefinition() there is a loop over the imports in order to resolve the WSDLDefinition. All the unresolved definitions are represented by the same WSDLDefinition object and the unresolved object becomes the resolved object. This is likely to end in tears if there is more than one import.