All right, I did some jax-ws pure stuff without using axis. I downloaded latest version of jax-ws lib at https://jax-ws.dev.java.net/2.1.5/JAXWS2.1.5-20081030.jar and create a new webapp at my tomcat With a web.xml with this content:
<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4"> <listener> <listener-class>com.sun.xml.ws.transport.http.servlet.WSServletContextLi stener</listener-class> </listener> <servlet> <servlet-name>myservice</servlet-name> <servlet-class>com.sun.xml.ws.transport.http.servlet.WSServlet</servlet- class> <load-on-startup>0</load-on-startup> </servlet> <servlet-mapping> <servlet-name>myservice</servlet-name> <url-pattern>/dostuff</url-pattern> </servlet-mapping> <session-config> <session-timeout>30</session-timeout> </session-config> </web-app> And other file sun-jaxws.xml (also in WEB-INF) <endpoints xmlns="http://java.sun.com/xml/ns/jax-ws/ri/runtime" version="2.0"> <endpoint name="Myservice" implementation="MyService" url-pattern="/dostuff"/> </endpoints> Just started my tomcat and magic!! The jax-ws worked perfectly! Now, how this thing is integrated with axis2 ????? I didn't see the libs of jax-ws at axis2, is it a separated download? All the .aar file is needed ??? Regards R -----Original Message----- From: Asensio, Rodrigo [mailto:[email protected]] Sent: Thursday, January 22, 2009 4:21 PM To: [email protected] Subject: rpc vs jax-ws My customer uses as client generator Microsoft BizTalk and I'm testing a generator with netbeans. I'm using axis2 as server with these message inout at the service.xml #message.receiver.inout=org.apache.axis2.rpc.receivers.RPCMessageReceive r #message.receiver.inonly=org.apache.axis2.rpc.receivers.RPCInOnlyMessage Receiver I'm returning POJO objects and arrays. Everything works perfectly if I do in the client side something like this String url = "http://localhost/axis/services/myservice"; ServiceClient client = new ServiceClient(); Options opts = new Options(); opts.setTimeOutInMilliSeconds(360000); opts.setTo(new EndpointReference(url)); opts.setAction("dosomething"); client.setOptions(opts); OMElement res = client.sendReceive(payload); The returning element is what I want, everything worked perfectly. Now, is this webservice RPC style, right ? not jax-ws ? Netbeans and biztalk generates the client stub but when executed nothing is filled (xml back seems OK), all objects are null. Should I develop jax-ws ??? Now, to develop jax-ws, I have to use annotations, right, like @WebService and @WebMethod.... I'm kind of lost. Thanks for your help. Regards Rodrigo Asensio http://www.rodrigoasensio.com Please be advised that this email may contain confidential information. If you are not the intended recipient, please do not read, copy or re-transmit this email. If you have received this email in error, please notify us by email by replying to the sender and by telephone (call us collect at +1 202-828-0850) and delete this message and any attachments. Thank you in advance for your cooperation and assistance. In addition, Danaher and its subsidiaries disclaim that the content of this email constitutes an offer to enter into, or the acceptance of, any contract or agreement or any amendment thereto; provided that the foregoing disclaimer does not invalidate the binding effect of any digital or other electronic reproduction of a manual signature that is included in any attachment to this email. Please be advised that this email may contain confidential information. If you are not the intended recipient, please do not read, copy or re-transmit this email. If you have received this email in error, please notify us by email by replying to the sender and by telephone (call us collect at +1 202-828-0850) and delete this message and any attachments. Thank you in advance for your cooperation and assistance. In addition, Danaher and its subsidiaries disclaim that the content of this email constitutes an offer to enter into, or the acceptance of, any contract or agreement or any amendment thereto; provided that the foregoing disclaimer does not invalidate the binding effect of any digital or other electronic reproduction of a manual signature that is included in any attachment to this email.
