0 Replies Latest reply on Jan 7, 2005 1:54 PM by Thomas Diesler

    JBossWS status

    Thomas Diesler Master

      First of all a happy new year, good health and lots of joy in 2005 and thanks for the good work that you put in last year.

      JAXRPC client status
      --------------------

      We are almost complete with the JAXRPC client layer. This allows us to invoke remote web services with DII like this

       ServiceFactory factory = ServiceFactory.newInstance();
       Service service = factory.createService(new QName("testService"));
      
       Call call = service.createCall();
       call.setOperationName(new QName("echoString"));
       call.addParameter("String_1", LiteralTypeMapping.XML_TYPE_STRING, ParameterMode.IN);
       call.setReturnType(LiteralTypeMapping.XML_TYPE_STRING);
      
       call.setTargetEndpointAddress("http://localhost:8080/jbossws-jaxrpc");
      
       String helloWorld = "Hello world!";
       Object retObj = call.invoke(new Object[]{helloWorld});
       assertEquals(helloWorld, retObj);
      


      configured from WSDL, like this

       URL wsdlLocation = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
       QName serviceName = new QName("http://org.jboss.ws/jaxrpc", "TestService");
       QName operationName = new QName("echoString");
      
       ServiceFactory factory = ServiceFactory.newInstance();
       Service service = factory.createService(wsdlLocation, serviceName);
      
       Call call = service.createCall();
       call.setOperationName(operationName);
       assertFalse(call.isParameterAndReturnSpecRequired(operationName));
      
       String helloWorld = "Hello world!";
       Object retObj = call.invoke(new Object[]{helloWorld});
       assertEquals(helloWorld, retObj);
      


      and using a dynamic proxy, like this

       URL wsdlLocation = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
       QName serviceName = new QName("http://org.jboss.ws/jaxrpc", "TestService");
      
       ServiceFactory factory = ServiceFactory.newInstance();
       Service service = factory.createService(wsdlLocation, serviceName);
      
       TestServiceEndpoint port = (TestServiceEndpoint)service.getPort(TestServiceEndpoint.class);
      
       String helloWorld = "Hello world!";
       String retObj = port.echoString(helloWorld);
       assertEquals(helloWorld, retObj);
      
      


      The forth and final client approach would be to use a propper J2EE WS client deployment and
      lookup the preconfigured service from JNDI, like this

       InitialContext iniCtx = new InitialContext();
       TestService service = (TestService)iniCtx.lookup("java:/comp/env/service/jaxrpc");
       TestServiceEndpoint port = service.getTestServiceEndpoint();
      
       String helloWorld = "Hello world!";
       String retObj = port.echoString(helloWorld);
       assertEquals(helloWorld, retObj);
      
      


      We have support for:

      * all valid JAXRPC types
      * all parameter modes (IN, INOUT, OUT)
      * parameters bound to header elements
      * unbound header elements
      * synchronous/asynchronous invocations

      Current limmitations are (in order of priority)

      * marshalling/unmarshalling of complex types http://jira.jboss.com/jira/browse/JBWS-43
      * fault messages http://jira.jboss.com/jira/browse/JBWS-47
      * client side handler chain http://jira.jboss.com/jira/browse/JBWS-50
      * support for attachments http://jira.jboss.com/jira/browse/JBWS-46

      SOAP with attachments (SwA) is a problem area which is fairly disconnected from the rest of the stack.

      As a result of insufficient support for complex types we are limitted to rpc/literal encoding.
      Remember with document/literal the whole message is a complex type.

      JAXRPC server status
      --------------------

      Currently all tests work with proper WS4EE deployments that run on the existing 4.0.x WS implementation on the server side.
      In other words, server side is still missing. Server side relies on WS configuration from WSDL (because there is no DII)
      As far as marshalling/unmarshalling is concerned there will be little difference from what we have on the client side.
      The server side deployment and JMX book keeping needs to be done and the POJO/EJB dispatching to the endpoint implementation bean.

      The aim is to get this done over the next two months ready for JBossWorld. This will then allow us to run the CTS (2200 tests) against the
      new implementation. When JBossWS passes the CTS and we see a comparable or better performance than with the existing Axis based implementation
      we will switch to JBossWS. This will probably be happening Q2/2005.

      JAXB integration
      ----------------

      JAXB is the marshalling layer mandated by JAXRPC-2.0. Currently we use the JAXB-1.1 API to delegate marshalling/unmarshalling of complex types.
      In WS4EE the XML/Java mapping is defined in the jaxrpc-mapping.xml descriptor, which we will have to support by spec. Defining mapping in
      yet another external XML descriptor is less than desirable and will give way to a more intuitive approach using annotations.

      Currently, the JAXB layer uses introspection to do the mapping. This will be replaced by jaxrpc-mapping.xml awareness. Mapping defined by annotations
      will be added later.

      JBossWS tools
      -------------

      The JBossWS tools (jbossws) will allow for offline generation of the WSDL, Service Endpoint Interface, Service Interface, complex user types, etc.
      A command line version as well as ant tasks will be provided. In this area work is in progress - no functioning implementation yet.
      Using wscompile is the recomended practice until we have a comparable impementation in place.

      The JBossWS team
      ----------------

      Anil is working on the tools. He is compiling a jbossws feature matrix, which will be published in the docbook.
      He is also doing research in WSDL-1.1 mapping onto a WSDL-2.0 object graph. This is of high importance as it needs to be decided whether we
      can continue working with WSDL-2.0 internally. The WS should ideally be unaware of the WSDL version.

      Alex is working on the marshalling layer. His next task is to implement a jaxrpc-mapping.xml aware marshaller/unmarshaller.

      Jason is looking at pull parser technology. The aim is to construct a flat SAAJ object graph during the first parse of the message
      that holds the already unmarshalled java objects at SOAPContentElement level. SOAPContentElements are described in the docbook.

      I'm working on the deployment layer, server side implementation, providing test cases, etc.