Uploaded image for project: 'Axis2'
  1. Axis2
  2. AXIS2-3668

Wrong JAX-WS handler-chain execution

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.4, nightly
    • jaxws
    • None
    • Apache Tomcat 5.5.25
      Axis2-1.4/RC2
      soapUI for client

    Description

      Hi all,

      I'm testing Axis2-1.4/RC2 and its JAX-WS handler framework implementation. I noticed some unconformities with the JAX-WS specification:

      I have a handler chain with Handler1, Handler2, Handler3 and Handler4. The four of them have handleMessage(), handleFault() and close() methods as well as init() and destroy() methods annotated with @PostConstruct and @PreDestroy respectively. When a message arrives init() is executed on all handlers, then on the inbound direction Handler3's handleMessage() method throws a ProtocolException -> then the chain is reverted and handleFault() is invoked on Handler2 and Handler1, then close() on Handler 1, 2 and 3. As far as I understand from the JAX-WS 2.0 specification this is the expected behavior. So here I expect all @PreDestroy methods to be executed and that's all for the handler-chain. BUT instead I can see that an outbound execution starts (with OUTBOUND_PROPERTY = true) and handleFault() is called (again) on all four handlers from 4 to 1, then close() on all handlers (again) and at the end destroy() on all handlers.

      I guess that somewhere you miss to check for errors on the inbound chain execution and a complete outbound chain is executed no matter what happened on the inbound direction. I think it is important to fix this.
      Thanks.

      Regards,
      Misho

      Attachments

        1. HelloServiceJAXWSAnnotated.aar
          2 kB
          Misho Gradinkata
        2. my-jaxws-handler-chain.jar
          13 kB
          Misho Gradinkata
        3. request.xml
          0.5 kB
          Misho Gradinkata

        Activity

          People

            Unassigned Unassigned
            misho Misho Gradinkata
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: