Results 1 to 2 of 2

Thread: using speing expressions

  1. #1

    Default using speing expressions

    I having trouble using the spring expressions


    I want to use spring expression for the bean below

    Code:
    	<jaxws:client id="client" serviceClass="SearchService"  address="#findUrl" >
    		<jaxws:outInterceptors>
    			<bean class="org.apache.cxf.binding.soap.saaj.SAAJOutInterceptor"/>
    			<ref bean="wss4jOutInterceptor" />
    		</jaxws:outInterceptors>
    		
    	</jaxws:client>
    #findUrl is a bean instead of this bean I wanted to use expression

    here the findUrlBean
    Code:
    	<bean id="findUrl" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
    	  <property name="targetObject" ref="systemProperties" />
    	  <property name="targetMethod"><value>getPropertyValue</value></property>
    	  <property name="arguments">
    	    <list>
    	      <value>find_service_url</value>
    	    </list>
    	  </property>
    	</bean>
    this is traditional method of retrieving a property and using it as a bean

    using expression I tried

    #{systemProperties.getPropertyValue('find_service_ url')}

    is this right way to use expressions ?
    I got the exception bean not found.Please help me use expressions correctly.

  2. #2

    Default

    please tell me how to use expression instead of MethodInvokingFactoryBean

    here i am using MethodInvokingFactoryBean


    Code:
    <bean id="findUrl" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
    	  <property name="targetObject" ref="systemProperties" />
    	  <property name="targetMethod"><value>getPropertyValue</value></property>
    	  <property name="arguments">
    	    <list>
    	      <value>find_service_url</value>
    	    </list>
    	  </property>
    	</bean>
    please tell me what is equivalent when using spring expressions?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •