java xml-rpc

Mina Amin minaavictor at
Tue Sep 25 14:09:43 UTC 2007

This is the code, i use to invoke the Bugzilla API, also I'm using version 3.0.1 and when invoking the Version API it return the it correctly.but the problem with the User.login API. XmlRpcClientConfigImpl config = new XmlRpcClientConfigImpl();
config.setServerURL(new URL("http://<VMware virtual IP>/bugzilla/xmlrpc.cgi"));
XmlRpcClient client = new XmlRpcClient();client.setConfig(config);
Object result = client.execute("User.login", new Object[] {"mina at", "password"});System.out.println(result);Note that execute takes a list or object[] as its second parameter.and the exception is 
Exception in thread "main" java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
at org.apache.xmlrpc.parser.XmlRpcResponseParser.addResult(
at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.endValueTag(
at org.apache.xmlrpc.parser.XmlRpcResponseParser.endElement(
at Source)
at Source)
at$ Source)
at Source)
at Source)
at Source)
at Source)
at Source)
at Source)
at Source)
at$JAXPSAXParser.parse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(
at org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(
at org.apache.xmlrpc.client.XmlRpcClient.execute(
at org.apache.xmlrpc.client.XmlRpcClient.execute(
at org.apache.xmlrpc.client.XmlRpcClient.execute( com.newportmediainc.bzc.executer.BZCApplication.main( and the TCP dump using wiresharkfaultString
Can't use string ("<email account>") as a HASH ref while "strict refs" in use at Bugzilla/WebService/ line 39.\nfaultcode 
server // i think this is the problem as it must return a numerical code.
I believe that the problem in how to send a parameters with the method name. so if anyone did it via java and apach xml-rpc please give a hand.

> Date: Mon, 24 Sep 2007 16:17:21 -0700> From: mkanat at> To: developers at> Subject: Re: java xml-rpc> > On Mon, 24 Sep 2007 13:20:59 +0000 Mina Amin <minaavictor at>> wrote:> > I'm developing a bugzilla client under java application that use> > bugzilla xml-rpc API, when using the "User.login" method a cast> > exception occurs.. any help NOTE: i'm using java 6 with apach xml-rpc> > library > > You're going to have to be way more specific than that. Show us> what code you wrote, and show us the exact error.> > Also, you're probably better off asking the people who wrote> the library, instead of us. As long as you're following the Bugzilla> API, you should be fine. Just realize that all arguments are a hash (a> Map in Java terms).> > -Max> -- >> Competent, Friendly Bugzilla Services. And Everything Else, too.
More photos; more messages; more whatever – Get MORE with Windows Live™ Hotmail®. NOW with 5GB storage.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the developers mailing list