Announcement Announcement Module
Collapse
No announcement yet.
BeanNameAutoProxyCreator: beanNames Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • BeanNameAutoProxyCreator: beanNames

    It would be nice that the beanNames properties would strip out white space so it would be easier to specify the names in a readable matter. Eg

    Instead of this:

    <bean id="serviceProxyCreator" class="org.springframework.aop.framework.autoproxy .BeanNameAutoProxyCreator">
    <property name="beanNames">
    <value>com.toto.pk.service1,com.toto.pk.service2,c om.toto.pk.service3,com.toto.pk.service4</value>
    </property>
    <property name="interceptorNames">
    <list>
    <value>debugInterceptor</value>
    </list>
    </property>
    </bean>

    Have this:

    <bean id="serviceProxyCreator" class="org.springframework.aop.framework.autoproxy .BeanNameAutoProxyCreator">
    <property name="beanNames">
    <value>
    com.toto.pk.service1,
    com.toto.pk.service2,
    com.toto.pk.service3,
    com.toto.pk.service4
    </value>
    </property>
    <property name="interceptorNames">
    <list>
    <value>debugInterceptor</value>
    </list>
    </property>
    </bean>

  • #2
    You can do it this way
    Code:
    <bean id="serviceProxyCreator"
          class="org.springframework.aop.framework.autoproxy.BeanNameAutoProxyCreator"> 
     <property name="beanNames"> 
      <list>
       <value>com.toto.pk.service1</value>
       <value>com.toto.pk.service2</value>
       <value>com.toto.pk.service3</value>
       <value>com.toto.pk.service4</value>
      </list> 
     </property> 
     <property name="interceptorNames"> 
      <list> 
       <value>debugInterceptor</value> 
      </list> 
     </property> 
    </bean>
    I think it is more readable now.

    Comment

    Working...
    X