Announcement Announcement Module
Collapse
No announcement yet.
Publish WSDL under configurable names? Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Publish WSDL under configurable names?

    I would like to publish my WSDL contracts under configurable names.

    A natural approach would look like this:

    Code:
    <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
    	<property name="properties">
    	    <props>
    	        <prop key="emp">Employee</prop>
    	    </props>
    	  </property>
    </bean>
    
    <bean id="${emp}" class="org.springframework.ws.wsdl.wsdl11.DefaultWsdl11Definition">
       <property name="locationUri" value="http://localhost"/>
       <property name="portTypeName" value="${emp}"/>
       <property name="schemaCollection">
    	<bean class="org.springframework.xml.xsd.commons.CommonsXsdSchemaCollection"> 
    		<property name="xsds"> 
    			<list><value>${emp}.xsd</value></list> 
    		</property> 
    		<property name="inline" value="true"/> 
    	</bean>
    	</property>
    </bean>
    Unfortunately, this won't work, since PropertyPlaceholderConfigurer will not configure placeholders in the bean id (or name) attributes. MessageDispatcherServlet logs:

    Code:
    Published [DefaultWsdl11Definition@2ed35cfe] as ${emp}.wsdl
    Any ideas on how to do this?
Working...
X