Hi James; I did the following and got the correct result - create a service archive file using your service impl class; - services.xml look like follows;
<service name="axisversion"> <messageReceivers> <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" class="org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver"/> <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" class="org.apache.axis2.rpc.receivers.RPCMessageReceiver"/> </messageReceivers> <parameter name="ServiceClass" locked="false">org.MyService1</parameter> </service> and I my service impl class is follows public class MyService1 { public void ping(int element) { } public int echo(int element) { return element * element; } } - I deploy the service archive file in tomcat (which is running in port 8080) - and then I type http://127.0.0.1:8080/axis2/rest/axisversion/echo?element=15 - got the following output <ns:echoResponse> <return>225</return> </ns:echoResponse> James Gan wrote: > Hi, dear all > > After installing AXIS war in Websphere Application Server, I can visit > Version service by inputting its address in the address bar of > browser. But I'm wondering if I can input parameters while visiting > follow service created by me. > > public class MyService1 { > public void ping(int element) { > > } > > public int echo(int element) { > return element * element; > } > } > > I input http://localhost:9080/axis2/rest/MyService1/ping?element=15 in > the address bar of firefox. Then I got follow error information: > > *Error Message: *Invalid message addition , operation context > completed; nested exception is: org.apache.axis2.AxisFault: Invalid > message addition , operation context completed > *Error Code: *500 > *Target Servlet: *AxisRESTServlet > *Error Stack: * > org.apache.axis2.AxisFault: Invalid message addition , operation > context completed; nested exception is: > org.apache.axis2.AxisFault: Invalid message addition , operation > context completed > at > org.apache.axis2.transport.http.util.RESTUtil.processGetRequest(RESTUtil.java:141) > > at > org.apache.axis2.transport.http.AxisRESTServlet.doGet(AxisRESTServlet.java:36) > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:743) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1282) > > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:673) > > > Is it feasible in AXIS2? > > Thanks a lot! > James Gan > -- Thanks, Deepal ................................................................ ~Future is Open~ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]