SWS-1090 - Add support for 'wsjar' protocol.

This commit is contained in:
Greg L. Turnquist
2020-09-14 12:34:34 -05:00
parent 41a38f70ad
commit 2a18b1d926

View File

@@ -20,6 +20,7 @@ import javax.xml.validation.SchemaFactory;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.util.ResourceUtils;
import org.xml.sax.SAXNotRecognizedException;
import org.xml.sax.SAXNotSupportedException;
@@ -49,7 +50,7 @@ public class SchemaFactoryUtils {
}
try {
schemaFactory.setProperty(XMLConstants.ACCESS_EXTERNAL_SCHEMA, "file,jar:file");
schemaFactory.setProperty(XMLConstants.ACCESS_EXTERNAL_SCHEMA, ResourceUtils.URL_PROTOCOL_FILE + "," + "jar:file" + "," + ResourceUtils.URL_PROTOCOL_WSJAR);
} catch (SAXNotRecognizedException | SAXNotSupportedException e) {
if (log.isWarnEnabled()) {
log.warn(XMLConstants.ACCESS_EXTERNAL_SCHEMA + " property not supported by " + schemaFactory.getClass().getCanonicalName());