cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrea Smyth <andrea.sm...@iona.com>
Subject Re: Enabling databinding schema validation configuration
Date Thu, 19 Oct 2006 12:56:33 GMT
Hi Jim,

Jim Ma wrote:

>Hi Andrea,
>
>I write the following snippet to configure service and port to enable schema validation
 :
>
><bean id="{http://apache.org/hello_world_soap_http}SOAPService" class="org.apache.cxf.service.ServiceImpl">
>        <property name="enableSchemaValidationForAllPorts" value="true"/>
></bean>
>  
>
This won't work as ServiceImpl does not have a setter for 
enableSchemaValidationForAllPorts, and no corresponding constructor 
either. More importantly, ServiceImpl is not meant to be constructed by 
the container.

><bean id="{http://apache.org/hello_world_soap_http}SOAPPort" class="org.apache.cxf.endpoint.EndpointImpl">
>        <property name="enableSchemaValidation" value="true"/>
></bean>   
>  
>
Same as above, EndpointImpl does not have a property named 
"enableSchemaValidation", and EndpointImpl instances cannot be 
instantiated by the container.
EndpointImpl however does have a property named "validation" - see 
org.apache.cxf.jaxws.ConfiguredEndpointTest and associated cfg file 
configured-endpoints.xml in module cxf-rt-frontend-jaxws. You should 
make this bean either lazy-init or abstract (and you can drop the 
classname).

>Is it the correct way ?  
>
>I have not found the code  to configure each operation in runtime. Is there any approach
to configure operation like calling configObject() to configure service ?
>  
>
You could (programatically) store the "enableValidation" property in the 
OperationInfo's map and write code that retrieves it from there and if 
necessary performs the validation - this is not in place AFAIK.

Andrea.

>Thanks
>
>Jim 
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>  
>


Mime
View raw message