Tech brief

Don picked up my posting on yawning, and also seems to be involved in a discussion about Wiki APIs.

First, a short explanation on the tech behind this weblog: This is an instance of JSPWiki, where each entry is a separate WikiPage. The Main page aggregates then all of the pages which have a certain signature in their name onto the front page, producing the weblog you see right now. This allows cool stuff like doing collection pages, such as Ropecon2003, or EGC2003, where I just insert a string like [{WeblogPlugin startDate='310103' days='31'}] to get all of the entries from January 2003, for example.

JSPWiki (and thus, this weblog) support the XML-RPC Wiki API, as well as the MetaWeblogAPI. The support for the latter is not complete, but it is quite enough so that I can moblog from my cell phone. What happens is that I basically send an email to a predefined address, where a custom script takes the email, parses it and posts it to the weblog using the said MetaWeblog API. The script is smart enough to take the attachments from the email and modify the entry so that they are properly inserted in the text. Of course, I have to write my entry using WikiMarkup, but trust me, it is far easier to do on a cell phone than HTML!

Yes, all Wikis use different markup rules - but actually, that's not really a big problem. So far, the biggest use of the WikiRPCInterface has been adding functionality into JSPWiki itself - a machine halfway across the world uses it to check up what has happened on the JSPWiki main site, and sends email to everyone who has subscribed to it. This is a highly important thing - I did not have to implement that by myself; I just implemented an API and someone else wrote it (thanks Mahlen!). This is really no different from writing a proper, plugin-based architecture for a Wiki, except that the external developer is no longer bound to Java, or Perl, or Python, or PHP, or whatever language the lead developer of the wiki decided to use. In essence, it allows you to write simple plugins and do batch processing on a Wiki without having to understand its internal implementation!

In fact, defining a standard markup language for Wikis (such as WikiML) should work well with this kind of an XML-RPC/SOAP API approach: just add another method that gets the text in WikiML instead of rendered HTML/WikiMarkup. It does not matter what markup the wikis themselves use.

I also believe that Wikis will converge slowly. It seems to me that MoinMoin style markup is winning, and with the stuff like Radeox from the SnipSnap folks, you can separate the rendering of the markup from the WikiEngine itself, making it largely irrelevant what markup people use, since you can just plug in the markup you want to use.

However, there will always be differences in markup. You see, doing stuff like complex TWiki markup just is out of the reach of the smaller players, and since making a basic wiki is really easy, people are not going to bother to use the same markup. They might adopt some common practices, but some wikis need stuff like syntax highlighting, and others will need direct drawing on page, etc... In the end, the one and only solution is to get rid of the markup altogether, and make a WYSIWYG wiki - sort of a distributed version of MS Word.

Phew. There is already a Wiki API standard, but so far not too many seem to have adopted it. I would very much like to see discussion what is needed, what is too much, and how to make it better.


Another possibility for someone demanding a Wiki API is Zope / Zwiki / Structured Text.

--jcwinnie, 06-Sep-2003

I also personally have high respect for the SnipSnap folks, who are doing a lot of interesting work, but they don't seem to be very active in the blogging world.

--JanneJalkanen, 07-Sep-2003

Thanks for the comment. I'm going to spend some time looking at the 1.0 version of the api first. I'll probably do a reference implementation as a goof and see how the usage models really shake out.

My prejudice is that the design direction you're going with the api is too broad, including an "everything for everybody" approach. But until I've got some code down, I won't know for sure what does & doesn't make sense.

--Mad William Flint, 07-Sep-2003

I find this whole argument about standard Wiki APIs a non-issue (and more than a hint of "API Control Freak Syndrome", but let's not get into that...).

I too agree that SnipSnap is underrated and not as well-known as it should be (most likely due to their own lack of ability to "sell" their concept), but it has made quite an influence on my own efforts. You can get PhpWiki to look a lot like SnipSnap (which was where I started).

But let's get to the point: after customizing a Wiki engine for a while, you realize there is no real reason for Wikis to have a specific API - that's just added semantic cruft, since the ones we already have work just fine.

As I commented somewhere in Don's blog, you can add Trackback, XML-RPC, SOAP or TheLatestBleedingEdgeAPI (missing link on purpose) to any well-designed Wiki framework. My own PHPWiki-based weblog will soon have Trackback (I've been putting it off for a long while, since I found per-node referrers to be much easier and with perfect cross-engine compatibility) and I've been looking at the MetaWebLog API too for a while now - but have little actual use for it, since even my cellphone allows me to edit my Wiki...

--Rui Carmo, 07-Sep-2003

Well... Some things like determining back and forward links from the resulting HTML can be a bit of a hassle, especially if you don't know which format a particular wiki uses. So I believe there are issues that cannot be solved satisfactorily with bolting... err, creative use of the existing weblog APIs.

See an example in JSPWiki:TouchGraphWikiBrowser on how the API can be used effectively to visualize a Wiki.

Besides, it's not like it's an OR-question - JSPWiki offers both the WikiRPCInterface and the MetaWeblogAPI - you use whatever tool you need to get the job done.

--JanneJalkanen, 08-Sep-2003

Your welcome, Janne! :)


--MahlenMorris, 13-Sep-2003

More info...     Comments?   Back to weblog
"Main_blogentry_060903_2" last changed on 06-Sep-2003 12:03:30 EEST by JanneJalkanen.