rmartinc commented on a change in pull request #904:
URL: https://github.com/apache/cxf/pull/904#discussion_r822511365
##########
File path:
rt/frontend/simple/src/main/java/org/apache/cxf/frontend/WSDLGetUtils.java
##########
@@ -566,9 +566,6 @@ private void processSchemaReference(SchemaReference
schemaReference,
doneSchemas.put(decodedStart, schemaReference);
doneSchemas.put(schemaReference.getReferencedSchema().getDocumentBaseURI(),
schemaReference);
- if (!doneSchemas.containsKey(decodedOrigLocation)) {
Review comment:
Done! The idea is the same one you presented before but in the other if.
Previously the schema was just discarded if it was already in the
`doneSchemas` map. But now it is checked if it's the same too (same uri). If
it's different then it's managed and the `decodedStart` is reset with the new
schema. That way the previous one added is overwritten.
IIUIC the problem is that the `decodedStart` is different between the
different files but it can collide with any other `decodedOrigLocation` (if
they happen to use the same include, but in different directory, as in the
example). Current implementation works if the `decodedStart` was inserted in
the map before the `decodedOrigLocation`, but not the other way around. With
this change we are always adding the `decodedStart`, no matter if it was
assigned before by a `decodedOrigLocation` of another schema.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]