【问题标题】:Migrate from Spring 2.5 to 3 within an existing Axis 1.4 webservice在现有的 Axis 1.4 Web 服务中从 Spring 2.5 迁移到 3
【发布时间】:2010-07-12 08:37:02
【问题描述】:

我必须从 Spring 2.5 迁移到 3.0。 我的 Web 服务仍在使用 Axis 1.4 运行, 在 Spring 2.5 中我相当简单,每个服务实现类都扩展了 ServletEndpointSupport。在 Spring 3.0 中,ServletEndpointSupport 已被弃用。

例如:

public class PersonBindingImpl extends ServletEndpointSupport implements PersonPortType {

    public PersonDaten PersonQueryRequest(XPAPersonRequest request) throws RemoteException, XPAException {
            PersonsImpl persons = getWebApplicationContext().getBean("personImpl", PersonsImpl.class);
            return persons.getAllByGroup(request.getGroup());
    }
}

有没有办法像在 Spring 2.5 中那样简单地在 Spring 3 中获取 ApplicationContext。

【问题讨论】:

    标签: java spring migration axis


    【解决方案1】:

    仅仅因为ServletEndpointSupport 已被弃用,并不意味着您不应该使用它,它只是意味着它只是为了支持过时或过时的机制——在本例中为 JAX-RPC(轴 1)。 ServletEndpointSupport 的 javadoc 说:

    已弃用以支持 JAX-WS org.springframework.remoting.jaxws

    换句话说,Axis 1 本身已经过时(如您所知),因此 Spring 3 没有为它提供最新的支持。

    这类似于 Spring 2.5 之前的大量应用程序仍然使用旧的 Controller 层次结构,该层次结构在 Spring 3 中已被弃用,但不会很快消失。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多