adding parent.xsd to PayloadValidatingInterceptor
authorGustavo Martin Morcuende <gu.martinm@gmail.com>
Thu, 4 Jun 2015 18:20:32 +0000 (20:20 +0200)
committerGustavo Martin Morcuende <gu.martinm@gmail.com>
Thu, 4 Jun 2015 18:20:32 +0000 (20:20 +0200)
web-services-spring-server/src/main/resources/spring-configuration/ws/soap-ws.xml

index cdf79a5..d77e7ab 100644 (file)
     </sws:dynamic-wsdl>
 
 
+    <bean id="ParentTypes" class="org.springframework.xml.xsd.SimpleXsdSchema">
+        <property name="xsd" value="classpath:parent.xsd"/>
+    </bean>
+
+
     <!-- Required in order to use SOAP 1.2
         id="messageFactory" is not a random choice, if you use another name it will not work
         (Spring will end up loading SOAP 1.1)
         -->
         <bean id="validatingInterceptor" 
             class="org.springframework.ws.soap.server.endpoint.interceptor.PayloadValidatingInterceptor">
-            <property name="schema" value="classpath:examples.xsd"/>
+            <property name="schemas">
+                <list>
+                    <value>classpath:examples.xsd</value>
+                    <value>classpath:parent.xsd</value>
+                </list>
+            </property>
             <property name="validateRequest" value="true"/>
             <property name="validateResponse" value="true"/>
         </bean>