I decided to use the XML-RPC standard in a project I’m working on, and meebey suggested that I release it as a separate project.
So here it is: Org.Cdh.Xmlrpc. Just svn co https://layla.chrishowie.com/svn/Xmlrpc
. No fancy reflection stuff yet. The library was designed to encapsulate the XML part of the XML-RPC spec without doing much else. (In other words, you need to handle the HTTP connection and map calls yourself.)
Why did you decide to use XML-RPC?
Because it’s a much easier standard for non-.NET apps to follow than .NET remoting.
Wouldn’t a normal REST-based architecture do much better?
Possibly. I’m not sure that there’s any significant difference in the difficulty of the backend implementation of either.
Probably not, but a REST-based solution would be a lot easier to test against, since it would support HTTP GET operations out of the box and would also support caching and other nice HTTP features out of the box. It would also be more interoperable since HTTP library availability is greater than that of XML-RPC libraries.
Oh, I think you misunderstood what I’m doing. I am using the XML specification from XML-RPC, but I am not running it over HTTP, just a straight TCP connection. (Or did you know that, and maybe I’m misunderstanding your comment?)
The project I’m using it in is a multiplayer card game, so I don’t think caching will be much of an issue. 🙂
Aha! Well, if you’re not using HTTP, then RESTful principles won’t matter much. I’d think it be a cool excercise to create a RESTful web service around a card game API, though. 🙂
Joe Gregorio has a handful of posts about how to create a RESTful web service:
http://bitworking.org/news/How_to_create_a_REST_Protocol
http://bitworking.org/news/132/REST-Tips-URI-space-is-infinite
http://bitworking.org/news/150/REST-Tip-Deep-etags-give-you-more-benefits
http://bitworking.org/news/141/REST-Tips-Prefer-following-links-over-URI-construction
http://bitworking.org/news/125/REST-and-WS
http://bitworking.org/news/201/RESTify-DayTrader
(I really hope these URIs make it through! No preview option, so I’m crossing my fingers.)
nice 😛 good explanation