Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

XML-RPC vs SOAP vs Custom

 
Pho Tek
Ranch Hand
Posts: 782
Chrome Python Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
SOAP is an overkill for my needs. So currently we're looking at writing our own custom XML transfer using servlets/URLconnection etc..
Could anyone who has some experience of using XML-RPC comment on its ability to validate types within the XML instance ? We're looking at sending:
integers
money (e.g. BigDecimal)
dates
strings
Also we need to be able to send a vector/struct like representation of stuff.
Cheers,
Pho
 
Devrim Turker
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
XML - RPC has
integer, boolean, string, double, date/time,
base 64 types
<?xml version="1.0"?>
<methodCall>
<methodName>GetCelcius</methodName>
<params>
<param>
<value><int>-5</int></value>
<param>
<params>
</methodCall>
a java Client sample
XmlRpcClient xmlrpc= new xmlRpcClient
"http://www.localhost.com/xmlrpc/server.asp");
Vector params =new Vector();
params.addElement(5000);
Integer retVal= (Integer) xmlrpc.execute("GetCurrentBalance", params);
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic