You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cxf.apache.org by GitBox <gi...@apache.org> on 2022/03/04 00:32:50 UTC
[GitHub] [cxf] reta commented on a change in pull request #904: [CXF-8655] Incorrect XSD resolution when the file name is the same in different folders
reta commented on a change in pull request #904:
URL: https://github.com/apache/cxf/pull/904#discussion_r819175354
##########
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:
@rmartinc my apologies for the delay, I would definitely prefer for @dkulp taking a look (I am missing context for initial implementation), but I believe we could make the change a bit safer (please feel free to suggest better way comparing schema references):
```suggestion
if (!doneSchemas.containsKey(decodedOrigLocation)) {
doneSchemas.put(decodedOrigLocation, schemaReference);
} else {
final SchemaReference ref = doneSchemas.get(decodedOrigLocation);
// Conflict detected: different schemas under same decodedOrigLocation
if (!ref.getSchemaLocationURI().equals(schemaReference.getSchemaLocationURI())) {
doneSchemas.remove(decodedOrigLocation);
}
}
```
Basically, the idea is - stick to previous behavior till the conflict is detected, wdyt @rmartinc ? thank you!
--
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: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org