« But, being productiv... | Main | Idea for Multi-Contr... »

MetaWeblog API support in Roller

<img src="http://www.rollerweblogger.org/resources/roller/bloggar.jpg" alt="Editing a Roller blog entry in w.bloggar"/>

Turns out, I didn't have to steal much code from Blojsom to get MetaWeblog API support going in Roller. I ended up only stealing method signatures, Javadocs, and logging statements (thanks guys!). Roller and Blojsom are so different and the Blogger and MetaWeblog APIs are so simplistic that no further theft was necessary. In the process, I learned about the simple and clean architecture of Blojsom and I learned that XML-RPC based Weblog APIs are a bit of a mess these days.

Looking at the Blojsom and Roller implementations of these APIs gives you a nice glimpse into the internals of these two Java-based weblogging systems. Take a look at the Blojsom impementations BlojsomBloggerAPIHandler.java and BlojsomMetaWeblogAPIHandler.java and you can see the essence of Blojsom: single-user blog implemented with file-system storage. Take a look at the Roller implementations BloggerAPIHandler.java and MetaWeblogAPIHandler.java and you can see the essence of Roller: multi-user blog implemented via business tier interfaces and POJOs. Take a look at channel 77 and you can see the Essence of Emeril: BAM!

In the end, I was able to implement all of the Blogger and MetaWeblog APIs except for the MetaWeblog API newMediaObject. Blojsom implements everything except getUserInfo, deletePost, getTemplate, setTemplate, getPost, and newMediaObject. I'm not sure all of those APIs are really all that useful anyway.

Even after implementing all of those APIs in the Roller "server," the job is not done. This is why I say that the APIs are a bit of a mess. Each server-side implementation is a little different. If you want to write a full-featured blogging client, then for each RPC method call you have to use conditional logic to determine based on the blogging server type which implementation is to be called. I'm not sure if this is due to a limitation of XML-RPC. Maybe XML-RPC based APIs are just too loose: after all, there is no WSDL equivalent for XML-RPC. Or, maybe XML-RPC is fine and only the differing implementations are to blame. I don't know. All I know is that I implementing the APIs is just not enough.

How can I say that? How do I know that my poor coding is not to blame? Take a look at w.bloggar and you'll see what I mean. The w.bloggar client is a very nice and full-featured blogging client. It supports titles, single-categories, multi-categories, template editing, and other things. Before I could get all of those features to work with Roller, I had to spend time tweaking the w.bloggar configuration file CMS.ini. Take a look at this troubling comment at the start of the CMS.ini file:

  ; Please don't change this file unless you know exactly what you're doing!
  ; And if you do be sure to make a backup of it.
  ;
  ;Values for *Method Options
  ; 0 - Not Supported Method
  ; 1 - Use Blogger API
  ; 2 - Use Blogger Pro API
  ; 3 - Use metaWeblog API
  ; 4 - Use MovableType API
  ; 5 - Use b2 API

This indicates a very sorry state of affairs. I was able to make all of the cool features of w.bloggar to work with Roller 0.9.7-dev by writing the configuration file section below, but other blogging clients still don't work completely. MozBlog, which appears to be somewhat flakey, and nntp//rss still don't work. Do I have to write configuration file for each blogging client I want to support? If so, I hope if they offer the same level of tweakability as w.bloggar.

  [CMS-11]
  Name=Roller
  URL=http://www.rollerweblogger.org
  Icon=rollerbadge.jpg
  Service=0
  Host=www.yourhost.com
  Page=/roller/xmlrpc
  Port=80
  Https=0
  MultiCateg=3
  GetCategMethod=3
  PostMethod=3
  GetPostsMethod=3
  TemplateMethod=1

Maybe it is time to retire the Blogging and MetaWeblog APIs. They are tired and they need some rest.

Comments:

You're most welcome!

Posted by David Czarnecki on April 13, 2003 at 12:06 AM EDT #

Post a Comment:
  • HTML Syntax: NOT allowed

« But, being productiv... | Main | Idea for Multi-Contr... »

Welcome

This is just one entry in the weblog Blogging Roller. You may want to visit the main page of the weblog

Related entries

Below are the most recent entries in the category Roller, some may be related to this entry.