Hi All!!
I am trying out a webservice in Axis..
I refered the javaworld's
"Axis: The next generation of Apache
SOAP " tutorial.
I tried a simple "HelloServer" program as webservice..
According to the
doc.. when I tried to compile the client..which used org.apache.axis.client.ServiceClient;
package.. it failed as the axis.jar didnot has this class.. I tried to download varios axis.jar but it didn't work..
I tried another client program pasted below.
import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
import org.apache.axis.encoding.XMLType;
import org.apache.axis.utils.Options;
import org.w3c.dom.*;
import javax.xml.rpc.ParameterMode;
import java.util.*;
public class Client1
{
public static void main(
String[] args) throws Exception
{
try{
String endpoint = "http://localhost:8080/axis/HelloServer.jws";
Service service = new Service();
Call call = (Call) service.createCall();
call.setTargetEndpointAddress(new java.net.URL(endpoint));
call.setOperationName( "sayHelloTo" );
call.addParameter("szProduct",XMLType.XSD_STRING,javax.xml.rpc.ParameterMode.IN);
call.setReturnType(org.apache.axis.encoding.XMLType.XSD_STRING);
String ret = (String)call.invoke( new Object [] { args[0] });
System.out.println(ret);
}catch(Exception e){System.out.println("Exception...::"+e.toString());}
}
}
It compiled and when I started running it I got the following exception
Exception in
thread "main" java.lang.NoClassDefFoundError: org.apache.commons.logging.LogFactory
My classpath includes all axis.jar,jaxrpc and log4j-core.jar..
can anyone plz help me to figureout where exactly I am going wrong?
Also is there any good document which expalins how to deploy a web application in websphere?
Thanks
Aastha
[ September 23, 2005: Message edited by: Aastha Surya ]