Skip to content

Commit

Permalink
dependency cleanup for prism-impl, removed cxf dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
1azyman committed Apr 15, 2020
1 parent 76cdb5a commit 9c22f39
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
10 changes: 2 additions & 8 deletions infra/prism-impl/pom.xml
Expand Up @@ -48,14 +48,8 @@
<artifactId>jaxb-xjc</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-wsdl</artifactId>
<exclusions>
<exclusion>
<groupId>javax.xml.stream</groupId>
<artifactId>stax-api</artifactId>
</exclusion>
</exclusions>
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-runtime</artifactId>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
Expand Down
Expand Up @@ -13,7 +13,7 @@
import com.evolveum.midpoint.util.exception.SchemaException;
import com.evolveum.midpoint.util.logging.Trace;
import com.evolveum.midpoint.util.logging.TraceManager;
import org.apache.cxf.wsdl.WSDLConstants;

import org.w3c.dom.Element;
import org.w3c.dom.Node;

Expand All @@ -29,6 +29,12 @@ class SchemaDescriptionParser {

private static final Trace LOGGER = TraceManager.getTrace(SchemaDescription.class);

public static final String NS_WSDL11 = "http://schemas.xmlsoap.org/wsdl/";

public static final QName QNAME_DEFINITIONS = new QName(NS_WSDL11, "definitions");

public static final QName QNAME_TYPES = new QName(NS_WSDL11, "types");

static SchemaDescriptionImpl parseResource(String resourcePath) throws SchemaException {
SchemaDescriptionImpl desc = new SchemaDescriptionImpl("system resource " + resourcePath, resourcePath);
desc.setStreamable(() -> {
Expand Down Expand Up @@ -57,8 +63,8 @@ static List<SchemaDescriptionImpl> parseWsdlResource(String resourcePath) throws
}
Element rootElement = node instanceof Element ? (Element) node : DOMUtil.getFirstChildElement(node);
QName rootElementQName = DOMUtil.getQName(rootElement);
if (WSDLConstants.QNAME_DEFINITIONS.equals(rootElementQName)) {
Element types = DOMUtil.getChildElement(rootElement, WSDLConstants.QNAME_TYPES);
if (QNAME_DEFINITIONS.equals(rootElementQName)) {
Element types = DOMUtil.getChildElement(rootElement, QNAME_TYPES);
if (types == null) {
LOGGER.warn("No <types> section in WSDL document in system resource " + resourcePath);
return schemaDescriptions;
Expand Down

0 comments on commit 9c22f39

Please sign in to comment.