diff options
2 files changed, 7 insertions, 0 deletions
diff --git a/sca-java-2.x/trunk/modules/binding-ws/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java b/sca-java-2.x/trunk/modules/binding-ws/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java index 9c2bbd6043..4863088cd5 100644 --- a/sca-java-2.x/trunk/modules/binding-ws/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java +++ b/sca-java-2.x/trunk/modules/binding-ws/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java @@ -135,6 +135,7 @@ public class WebServiceBindingProcessor extends BaseStAXArtifactProcessor implem if (uri != null) { wsBinding.setURI(uri); + // BWS20001 if (context.getParentModel() instanceof Reference){ try { URI tmpURI = new URI(uri); @@ -164,6 +165,11 @@ public class WebServiceBindingProcessor extends BaseStAXArtifactProcessor implem String localName = wsdlElement.substring(index + 1); if (localName.startsWith("wsdl.service")) { + // BWS20003 + if (context.getParentModel() instanceof org.apache.tuscany.sca.assembly.Service){ + error(monitor, "WSDLServiceOnService", reader, wsdlElement); + } + // Read a wsdl.service localName = localName.substring("wsdl.service(".length(), localName.length() - 1); wsBinding.setServiceName(new QName(namespace, localName)); diff --git a/sca-java-2.x/trunk/modules/binding-ws/src/main/resources/binding-wsxml-validation-messages.properties b/sca-java-2.x/trunk/modules/binding-ws/src/main/resources/binding-wsxml-validation-messages.properties index d8ecef91ef..4e88c5bcce 100644 --- a/sca-java-2.x/trunk/modules/binding-ws/src/main/resources/binding-wsxml-validation-messages.properties +++ b/sca-java-2.x/trunk/modules/binding-ws/src/main/resources/binding-wsxml-validation-messages.properties @@ -27,6 +27,7 @@ WsdlPortTypeDoesNotMatch = The #wsdl.port({0}) does not match with the WSDL Defi WsdliLocationMissingWsdlElement = binding.ws has a @wsdli:wsdlLocation attribute but no @wsdlElement attribute URINotAbsolute = [BWS20001] The URI value for binding.ws on an SCA reference must be absolute. Non-absolute value found {0} InvalidURISyntax = The URI value {0} found on binding.ws has invalid syntax +WSDLServiceOnService = [BWS20003] The wsdlElement attribute of a binding.ws on an SCA service must not specify the wsdl.service form of URI. The following URI was found {0} |