geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <david_jen...@yahoo.com>
Subject Re: WSDD Builder Error
Date Mon, 05 Sep 2005 20:36:52 GMT
You would get the same error from head.

I am not enough of an xml schema expert to know for sure, but I think 
your wsdl has an error that is causing the NPE.  I believe that the 
targetNamespace element needs to be in the schema element in order for 
it to actually apply to the schema.  I think that only namespace prefix 
definitions are "inherited" from an enclosing xml document.  Do you or 
anyone else know for sure about this?

In any case, I wrote a little test case that passes when the schema 
looks like:

<?xml version="1.0" encoding="UTF-8"?>
<schema
     targetNamespace="http://ormondquay.org/types"
     xmlns:xsd="http://www.w3.org/2001/XMLSchema"
     xmlns="http://www.w3.org/2001/XMLSchema">
     <element name="RequestWrapper" type="xsd:anyType"/>
     <element name="ResponseWrapper" type="xsd:anyType"/>
     <element name="PolicyRequestWrapper" type="xsd:anyType"/>
     <element name="PolicyResponseWrapper" type="xsd:anyType"/>
     <element name="AddPolicyRequestWrapper" type="xsd:anyType"/>
     <element name="AddPolicyResponseWrapper" type="xsd:anyType"/>
</schema>

and fails with:

<?xml version="1.0" encoding="UTF-8"?>
<schema
     targetNamespace=""
     xmlns:xsd="http://www.w3.org/2001/XMLSchema"
     xmlns="http://www.w3.org/2001/XMLSchema">
     <element name="RequestWrapper" type="xsd:anyType"/>
     <element name="ResponseWrapper" type="xsd:anyType"/>
     <element name="PolicyRequestWrapper" type="xsd:anyType"/>
     <element name="PolicyResponseWrapper" type="xsd:anyType"/>
     <element name="AddPolicyRequestWrapper" type="xsd:anyType"/>
     <element name="AddPolicyResponseWrapper" type="xsd:anyType"/>
</schema>

So, I suggest copying the targetNamespace attribute into the schema 
until we can figure out the correct behavior and implement it.

Many thanks
david jencks


On Sep 5, 2005, at 12:44 PM, Paul O'Connor wrote:

> M4...should I try it from the head?
>
> --- David Jencks <david_jencks@yahoo.com> wrote:
>
>> Great!  Which geronimo version are you using? M4?
>> svn revision ???  The
>> line number from the stack trace in your previous
>> post didn't match my
>> svn head version.
>>
>> thanks
>> david jencks
>>
>> On Sep 5, 2005, at 12:15 PM, Paul O'Connor wrote:
>>
>>> Thanks for the instantaneous response!  I actually
>>> don't have a Geronimo-specific war yet...trying to
>> get
>>> to that point ;-)
>>>
>>> Here is the jaxrpc-mapping.xml file:
>>>
>>> <?xml version="1.0" encoding="UTF-8"?>
>>> <java-wsdl-mapping version="1.1"
>>> xmlns="http://java.sun.com/xml/ns/j2ee"
>>>
>>
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>>
>> xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
>>>
>>
> http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
>>> <package-mapping>
>>>
>>
> <package-type>com.ormondquay.webservices</package-type>
>>>
>>
> <namespaceURI>http://ormondquay.org/types</namespaceURI>
>>> </package-mapping>
>>> <package-mapping>
>>>
>>
> <package-type>com.ormondquay.webservices</package-type>
>>>
>>
> <namespaceURI>http://ormondquay.org/types</namespaceURI>
>>> </package-mapping>
>>>
>>> <service-interface-mapping>
>>> <service-
>>>
>>
> interface>com.ormondquay.webservices.SamlXacmlRequestService</service-
>>
>>> interface>
>>> <wsdl-service-name
>>>
>>
> xmlns:serviceNS="http://ormondquay.org/types">serviceNS:
>>
>>> SamlXacmlRequestService</wsdl-service-name>
>>> <port-mapping>
>>> <port-name>SamlXacmlRequestPort</port-name>
>>>
>>
> <java-port-name>SamlXacmlRequestPort</java-port-name>
>>> </port-mapping>
>>> </service-interface-mapping>
>>>
>>> <service-endpoint-interface-mapping>
>>>
>>> <service-endpoint-
>>>
>>
> interface>com.ormondquay.webservices.SamlXacmlRequest</service-
>>
>>> endpoint-interface>
>>> 	<wsdl-port-type
>>>
>>
> xmlns:portTypeNS="http://ormondquay.org/types">portTypeNS:OQ-
>>
>>> SamlXacmlRequest</wsdl-port-type>
>>> 	<wsdl-binding
>>>
>>
> xmlns:bindingNS="http://ormondquay.org/types">bindingNS:OQ-
>>
>>> SamlXacmlRequestBinding</wsdl-binding>
>>>
>>> 	<service-endpoint-method-mapping>
>>> 	
>>>
>>
> <java-method-name>XACMLAuthzDecisionQuery</java-method-name>
>>> 	
>>>
>>
> <wsdl-operation>XACMLAuthzDecisionQuery</wsdl-operation>
>>> 		<method-param-parts-mapping>
>>> 			<param-position>0</param-position>
>>> 			<param-type>org.w3c.dom.Element</param-type>
>>> 			<wsdl-message-mapping>
>>> 				<wsdl-message
>>>
>>
> xmlns:wsdlMsgNS="http://ormondquay.org/types">wsdlMsgNS:
>>
>>> MessageEndpoint_processElement</wsdl-message>
>>> 			
>>>
>>
> <wsdl-message-part-name>RequestWrapper</wsdl-message-part-name>
>>> 				<parameter-mode>IN</parameter-mode>
>>> 			</wsdl-message-mapping>
>>> 		</method-param-parts-mapping>
>>> 		<wsdl-return-value-mapping>
>>> 		
>>>
>>
> <method-return-value>org.w3c.dom.Element</method-return-value>
>>> 			<wsdl-message
>>>
>>
> xmlns:wsdlMsgNS="http://ormondquay.org/types">wsdlMsgNS:
>>
>>>
>>
> MessageEndpoint_processElementResponse</wsdl-message>
>>> 		
>>>
>>
> <wsdl-message-part-name>ResponseWrapper</wsdl-message-part-name>
>>> 		</wsdl-return-value-mapping>
>>> 	</service-endpoint-method-mapping>
>>> 	<service-endpoint-method-mapping>
>>> 	
>>>
>>
> <java-method-name>XACMLPolicyQuery</java-method-name>
>>> 	
>> <wsdl-operation>XACMLPolicyQuery</wsdl-operation>
>>> 		<method-param-parts-mapping>
>>> 			<param-position>0</param-position>
>>> 			<param-type>org.w3c.dom.Element</param-type>
>>> 			<wsdl-message-mapping>
>>> 				<wsdl-message
>>>
>>
> xmlns:wsdlMsgNS="http://ormondquay.org/types">wsdlMsgNS:
>>
>>>
>> MessageEndpoint_processPolicyElement</wsdl-message>
>>> 			
>>>
>>
> <wsdl-message-part-name>PolicyRequestWrapper</wsdl-message-part-name>
>>> 				<parameter-mode>IN</parameter-mode>
>>> 			</wsdl-message-mapping>
>>> 		</method-param-parts-mapping>
>>> 		<wsdl-return-value-mapping>
>>> 		
>>>
>>
> <method-return-value>org.w3c.dom.Element</method-return-value>
>>> 			<wsdl-message
>>>
>>
> xmlns:wsdlMsgNS="http://ormondquay.org/types">wsdlMsgNS:
>>
>>>
>>
> MessageEndpoint_processPolicyElementResponse</wsdl-message>
>>> 		
>>>
>>
> <wsdl-message-part-name>PolicyResponseWrapper</wsdl-message-part-name>
>>> 		</wsdl-return-value-mapping>
>>> 	</service-endpoint-method-mapping>
>>> 	<service-endpoint-method-mapping>
>>> 	
>>>
>>
> <java-method-name>XACMLAddPolicyQuery</java-method-name>
>>> 	
>> <wsdl-operation>XACMLAddPolicyQuery</wsdl-operation>
>>> 		<method-param-parts-mapping>
>>> 			<param-position>0</param-position>
>>> 			<param-type>org.w3c.dom.Element</param-type>
>>> 			<wsdl-message-mapping>
>>> 				<wsdl-message
>>>
>>
> xmlns:wsdlMsgNS="http://ormondquay.org/types">wsdlMsgNS:
>>
>>>
>>
> MessageEndpoint_processAddPolicyElement</wsdl-message>
>>> 			
>>>
>>
> <wsdl-message-part-name>AddPolicyRequestWrapper</wsdl-message-part-
>>
>>> name>
>>> 				<parameter-mode>IN</parameter-mode>
>>> 			</wsdl-message-mapping>
>>> 		</method-param-parts-mapping>
>>> 		<wsdl-return-value-mapping>
>>> 		
>>>
>>
> <method-return-value>org.w3c.dom.Element</method-return-value>
>>> 			<wsdl-message
>>>
>>
> xmlns:wsdlMsgNS="http://ormondquay.org/types">wsdlMsgNS:
>>
>>>
>>
> MessageEndpoint_processAddPolicyElementResponse</wsdl-message>
>>> 		
>>>
>>
> <wsdl-message-part-name>AddPolicyResponseWrapper</wsdl-message-part-
>>
>>> name>
>>> 		</wsdl-return-value-mapping>
>>> 	</service-endpoint-method-mapping>
>>> </service-endpoint-interface-mapping>
>>>
>>>
>>> </java-wsdl-mapping>
>>>
>>
>>
>


Mime
View raw message