Has anybody try to use the EditGrid web services ? Here is what I got ?
Any idea what is wrong ?
I join my sample code that use the dynamic client, for that service
you don't need any
app-key
Cheers
tog
[EMAIL PROTECTED]:~$ java EditGridXfire
log4j:WARN No appenders could be found for logger
(org.codehaus.xfire.transport.DefaultTransportManager).
log4j:WARN Please initialize the log4j system
properly.
org.codehaus.xfire.XFireRuntimeException: Could not
invoke service.. Nested exception is
org.codehaus.xfire.fault.XFireFault: Unknown Error
org.codehaus.xfire.fault.XFireFault: Unknown Error
at
org.codehaus.xfire.fault.Soap11FaultSerializer.readMessage(Soap11FaultSerializer.java:31)
at
org.codehaus.xfire.fault.SoapFaultSerializer.readMessage(SoapFaultSerializer.java:28)
at
org.codehaus.xfire.soap.handler.ReadHeadersHandler.checkForFault(ReadHeadersHandler.java:111)
at
org.codehaus.xfire.soap.handler.ReadHeadersHandler.invoke(ReadHeadersHandler.java:67)
at
org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131)
at
org.codehaus.xfire.client.Client.onReceive(Client.java:382)
at
org.codehaus.xfire.transport.http.HttpChannel.sendViaClient(HttpChannel.java:139)
at
org.codehaus.xfire.transport.http.HttpChannel.send(HttpChannel.java:48)
at
org.codehaus.xfire.handler.OutMessageSender.invoke(OutMessageSender.java:26)
at
org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131)
at
org.codehaus.xfire.client.Invocation.invoke(Invocation.java:75)
at
org.codehaus.xfire.client.Client.invoke(Client.java:335)
at
org.codehaus.xfire.client.XFireProxy.handleRequest(XFireProxy.java:77)
at
org.codehaus.xfire.client.XFireProxy.invoke(XFireProxy.java:57)
at $Proxy6.doEcho(Unknown Source)
at EditGridXfire.echo(EditGridXfire.java:38)
at EditGridXfire.main(EditGridXfire.java:25)
import java.net.MalformedURLException;
import java.net.URL;
import editgrid.api.*;
import javax.xml.namespace.QName;
import org.codehaus.xfire.client.Client;
import org.codehaus.xfire.client.XFireProxy;
import org.codehaus.xfire.client.XFireProxyFactory;
import org.codehaus.xfire.service.Service;
import org.codehaus.xfire.service.binding.ObjectServiceFactory ;
import org.codehaus.xfire.transport.Channel;
public class EditGridXfire {
final static String WSDL = "http://www.editgrid.com/static/EditGrid.wsdl ";
final static String appKey = "my-secret-editgrid-key";
public EditGridXfire(){
}
public static void main(String[] args){
try {
(new EditGridXfire()).echo("test");
} catch (Exception e) {
e.printStackTrace();
}
}
public void echo(String message) throws MalformedURLException, Exception {
String serviceURL = "http://www.editgrid.com/api/soap";
Service serviceModel = new ObjectServiceFactory().create(EditGridPort.class);
XFireProxyFactory serviceFactory = new XFireProxyFactory();
try {
EditGridPort service = (EditGridPort) serviceFactory.create(serviceModel, serviceURL);
System.out.println((String)service.doEcho(message));
} catch (Exception e) {
e.printStackTrace();
}
}
}
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email