jax-ws
  1. jax-ws
  2. JAX_WS-512

-XadditionalHeaders doesn't add headers to async methods

    Details

    • Type: New Feature New Feature
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: current
    • Fix Version/s: not determined
    • Component/s: wsimport
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

      Description

      When -XadditionalHeaders is combined with <jaxws:enableAsyncMapping>, headers
      are added to synchronous methods, but not to asynchronous methods:

      public String messageSend(
      @WebParam(name = "regionID", targetNamespace =
      "http://cpdirect.centerpost.com/")
      String regionID,
      @WebParam(name = "messageDoc", targetNamespace =
      "http://cpdirect.centerpost.com/")
      MessageDoc40 messageDoc,
      @WebParam(name = "authentication", targetNamespace =
      "http://cpdirect.centerpost.com/", header = true, partName = "authentication")
      Authentication40 authentication);

      public Future<?> messageSendAsync(
      @WebParam(name = "regionID", targetNamespace =
      "http://cpdirect.centerpost.com/")
      String regionID,
      @WebParam(name = "messageDoc", targetNamespace =
      "http://cpdirect.centerpost.com/")
      MessageDoc40 messageDoc,
      @WebParam(name = "asyncHandler", targetNamespace = "")
      AsyncHandler<MessageSendResponse> asyncHandler);

      Authentication40 should be added to both.

        Activity

        Hide
        jitu added a comment -

        Not for 2.1.3.1

        Show
        jitu added a comment - Not for 2.1.3.1
        Hide
        jwofford added a comment -

        Headers are also not added to the polling asynchronous methods:

        public Response<MessageSendResponse> messageSendAsync(
        @WebParam(name = "regionID", targetNamespace =
        "http://cpdirect.centerpost.com/")
        String regionID,
        @WebParam(name = "messageDoc", targetNamespace =
        "http://cpdirect.centerpost.com/")
        MessageDoc40 messageDoc);

        Show
        jwofford added a comment - Headers are also not added to the polling asynchronous methods: public Response<MessageSendResponse> messageSendAsync( @WebParam(name = "regionID", targetNamespace = "http://cpdirect.centerpost.com/") String regionID, @WebParam(name = "messageDoc", targetNamespace = "http://cpdirect.centerpost.com/") MessageDoc40 messageDoc);
        Hide
        scm_issue_link added a comment -

        Code changed in jax-ws-sources
        User: ramapulavarthi
        Path:
        /jax-ws-sources/jaxws-ri/tools/wscompile/src/com/sun/tools/ws/processor/modeler/wsdl/PseudoSchemaBuilder.java (1.15.2.3)
        /jax-ws-sources/jaxws-ri/tools/wscompile/src/com/sun/tools/ws/processor/modeler/wsdl/WSDLModeler.java (1.15.2.5)
        /jax-ws-sources/jaxws-ri/tools/wscompile/src/com/sun/tools/ws/processor/modeler/wsdl/WSDLModelerBase.java (1.18.2.2)
        http://fisheye5.cenqua.com/changelog/jax-ws-sources/?cs=jaxws22:ramapulavarthi:20091010011312

        Log:
        JAX-WS-512: Partial fix for -XadditionalHeaders option for async methods.
        Now the response beans are generated with additional headers, but input extra headers are not taken care of yet.
        TODO: Lot of complexity in generating the right signature for async methods with -XadditionalHeaders in SEI as it needs to deal with input headers..

        Show
        scm_issue_link added a comment - Code changed in jax-ws-sources User: ramapulavarthi Path: /jax-ws-sources/jaxws-ri/tools/wscompile/src/com/sun/tools/ws/processor/modeler/wsdl/PseudoSchemaBuilder.java (1.15.2.3) /jax-ws-sources/jaxws-ri/tools/wscompile/src/com/sun/tools/ws/processor/modeler/wsdl/WSDLModeler.java (1.15.2.5) /jax-ws-sources/jaxws-ri/tools/wscompile/src/com/sun/tools/ws/processor/modeler/wsdl/WSDLModelerBase.java (1.18.2.2) http://fisheye5.cenqua.com/changelog/jax-ws-sources/?cs=jaxws22:ramapulavarthi:20091010011312 Log: JAX-WS-512: Partial fix for -XadditionalHeaders option for async methods. Now the response beans are generated with additional headers, but input extra headers are not taken care of yet. TODO: Lot of complexity in generating the right signature for async methods with -XadditionalHeaders in SEI as it needs to deal with input headers..
        Hide
        ramapulavarthi added a comment -

        -XadditionalHeaders is a unsupported extension option and does not effect the
        RI behavior and compatibility.
        Adding keyword metro2.0-waived

        Show
        ramapulavarthi added a comment - -XadditionalHeaders is a unsupported extension option and does not effect the RI behavior and compatibility. Adding keyword metro2.0-waived
        Hide
        gmazza added a comment -

        In the meantime one can probably use CXF's wsdl2java to generate the headers on
        the async methods while still using the Metro runtime (CXF does not have this
        problem), but it would be really nice if this could work out-of-the-box with
        Metro. (I'd like to switch from Axis2 to either CXF or Metro at work, using the
        argument of the relative ease that we can switch between the latter two stacks
        as future needs dictate. Fixing this particular bug--i.e., truly allowing us to
        be either 100% CXF or 100% Metro--will help make this argument more persuasive.)

        Show
        gmazza added a comment - In the meantime one can probably use CXF's wsdl2java to generate the headers on the async methods while still using the Metro runtime (CXF does not have this problem), but it would be really nice if this could work out-of-the-box with Metro. (I'd like to switch from Axis2 to either CXF or Metro at work, using the argument of the relative ease that we can switch between the latter two stacks as future needs dictate. Fixing this particular bug--i.e., truly allowing us to be either 100% CXF or 100% Metro--will help make this argument more persuasive.)
        Hide
        ramapulavarthi added a comment -

        Marking this as feature as this is for unsupported wsimport option. Waived for JAX-WS 2.2.2 as it involves lot of complexity in getting it right without regressions esp with parameter order etc.

        Show
        ramapulavarthi added a comment - Marking this as feature as this is for unsupported wsimport option. Waived for JAX-WS 2.2.2 as it involves lot of complexity in getting it right without regressions esp with parameter order etc.

          People

          • Assignee:
            Unassigned
            Reporter:
            jwofford
          • Votes:
            1 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: