Link to home
Start Free TrialLog in
Avatar of komlaaa
komlaaa

asked on

org.apache.xmlrpc.XmlRpcException

Hi,
I am geting :
org.apache.xmlrpc.XmlRpcClientException: Failure writing request
...
 Caused by: org.apache.xmlrpc.XmlRpcException: Unsupported Java type: class java.util.HashMap

Please take a look at the snippet below help out with what i should correct.

=================== code snippet =========
                  HashMap structMap = (HashMap) mySumAndUserDetails.get("userDetails");
                  String email = (String) mySumAndUserDetails.get("email");
                  mySumAndUserDetails.remove("flag"); // ===> email should be in structMap values.
                  Integer checksum = (Integer)mySumAndUserDetails.get("sum") ;
                  
                  try{
                    XmlRpcClient xmlrpc = new XmlRpcClient ( endpoint );
                          Vector<Object> params = new Vector<Object>(Arrays.asList(new Object[] {"oi-test", email, checksum, structMap, "dh-wrs" }));
                      status = (Object)xmlrpc.execute ("signup_createNewUser", params);  <============
ASKER CERTIFIED SOLUTION
Avatar of arun_kuttz
arun_kuttz

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of arun_kuttz
arun_kuttz

or u could just replace :

Vector<Object> params = new Vector<Object>(Arrays.asList(new Object[] {"oi-test", email, checksum, structMap, "dh-wrs" }));

with

Vector<Object> params = new Vector<Object>(Arrays.asList(new Object[] {"oi-test", email, checksum, new Hashtable(structMap), "dh-wrs" }));

-KuTtZ