Multiple resouceBean configuration in CXF using Spring

前端 未结 4 994
迷失自我
迷失自我 2021-01-03 08:06

I\'m using CXF RS 2.5.1 with Spring 3.0.6-RELEASE. I would like to have multiple implementation classes for \"a single endpoint\". I see that this issue was reported and fix

4条回答
  •  失恋的感觉
    2021-01-03 08:36

    I'd solve the problem this way:

    • Removing a "Custom Resource Comparator" (there's no need to)

    • Removing this:

      
          org.apache.cxf
          cxf-bundle-jaxrs
          2.5.0
       
      
    • In the account-servlet.xml/applicationContext:

      
          
              
                  
                  
              
          
      
      
    • In the beans/class implementation:

      ...
      @Context("accountServiceImpl")
      @Path("/account")
      public class Accountservice{
      ...
      

    And that's all. :)

提交回复
热议问题