You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@ws.apache.org by Rutger Heijmerikx <ru...@checksum.org> on 2006/03/31 13:44:52 UTC

Failed to parse servers response: Unknown type: string

Hi list,

After spending quite some time getting the client and server parts of
the xmlrpc to run i've finally have some results. The Calculator
example is running. :)

Now, i wanted to try another real life example but that didn't work
out at all for me yet.
I tried pinging blo.gs using the xmlrpc client mentioned below.

(http://www.xmlrpc.com/weblogsCom)

private void pingBlogs()
	{
		
	    try {
			XmlRpcClientConfigImpl config = new XmlRpcClientConfigImpl();
			config.setServerURL(new URL("http://ping.blo.gs"));
			XmlRpcClient client = new XmlRpcClient();
			client.setConfig(config);
			Object[] params = new Object[]{new String("example.com"), new
String("http://www.example.com")};
			String result = (String) client.execute("weblogUpdates.ping", params);
			System.out.println(result);
		} catch (MalformedURLException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (XmlRpcException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}

Running this client results in the following stack trace:

org.apache.xmlrpc.client.XmlRpcClientException: Failed to parse
servers response: Unknown type: string
	at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStreamTransport.java:267)
	at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:216)
	at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:53)
	at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
	at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
	at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
	at org.checksum.xmlrpc.XmlRpcTestClient.pingBlogs(XmlRpcTestClient.java:86)
	at org.checksum.xmlrpc.XmlRpcTestClient.main(XmlRpcTestClient.java:23)
Caused by:
org.xml.sax.SAXParseException: Unknown type: string
	at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(RecursiveTypeParserImpl.java:115)
	at org.apache.xmlrpc.parser.MapParser.startElement(MapParser.java:137)
	at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(RecursiveTypeParserImpl.java:126)
	at org.apache.xmlrpc.parser.XmlRpcResponseParser.startElement(XmlRpcResponseParser.java:126)
	at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
	at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown
Source)
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
Source)
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
	at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
	at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
	at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStreamTransport.java:265)
	at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:216)
	at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:53)
	at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
	at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
	at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
	at org.checksum.xmlrpc.XmlRpcTestClient.pingBlogs(XmlRpcTestClient.java:86)
	at org.checksum.xmlrpc.XmlRpcTestClient.main(XmlRpcTestClient.java:23)




Is anyone willing to give me a pointer on were to look?

Thanks in advance for any help.

Re: Failed to parse servers response: Unknown type: string

Posted by Jose Luis Cruz <jl...@ravenpack.com>.
On Tuesday 04 April 2006 21:47, Rutger Heijmerikx wrote:
> On 4/4/06, Walter Mundt <Wa...@coleengineering.com> wrote:
> > > org.apache.xmlrpc.client.XmlRpcClientException: Failed to parse
> > > servers response: Unknown type: string
> > > Is anyone willing to give me a pointer on were to look?
> >
> > This is a known bug with the last released version of the library.  It's
> > fixed in CVS, so try the nightly builds here:
> >
> > http://cvs.apache.org/dist/ws/xmlrpc/nightly
>
> Thanks, that did the trick indeed.

Thank you very much! I should have checked the concurrent version before 
spending some hours looking for the bug. At least I've noticed in the code 
that is the same I found.

It seems to work perfectly now.

Regards,
jlcruz

Re: Failed to parse servers response: Unknown type: string

Posted by Rutger Heijmerikx <ru...@checksum.org>.
On 4/4/06, Walter Mundt <Wa...@coleengineering.com> wrote:
> > org.apache.xmlrpc.client.XmlRpcClientException: Failed to parse
> > servers response: Unknown type: string
> > Is anyone willing to give me a pointer on were to look?
>
> This is a known bug with the last released version of the library.  It's
> fixed in CVS, so try the nightly builds here:
>
> http://cvs.apache.org/dist/ws/xmlrpc/nightly
>
>
>
>

Thanks, that did the trick indeed.

Re: Failed to parse servers response: Unknown type: string

Posted by Walter Mundt <Wa...@coleengineering.com>.
> org.apache.xmlrpc.client.XmlRpcClientException: Failed to parse
> servers response: Unknown type: string
> Is anyone willing to give me a pointer on were to look?

This is a known bug with the last released version of the library.  It's 
fixed in CVS, so try the nightly builds here:

http://cvs.apache.org/dist/ws/xmlrpc/nightly