All posts by BrigetteK

If you have a Deki VM, It is now easy to migrate an existing MediaWiki installation to Deki!  Requirements:

- MediaWiki 1.10 (or later)
- Deki VM 8.08 (or later)

The conversion process simply involves entering MediaWiki’s settings into a configuration file and launching the converter.  Your MediaWiki page revision history, content, users, files, etc. will all be directly imported into your Deki VM.  Learn more about it here.

While working on our MediaWiki to Deki Wiki converter, I needed to convert a MediaWiki site running in multiple languages. This functionality was implemented using a MediaWiki instance for each language. The approach is problematic since wiki management needs to be handled separately for each language; users had to maintain a user page per language, the same extensions were registered for each instance, common templates could not be leveraged, and there was no easy mechanism for performing cross-language searches. Thus, we were inspired to support multiple languages within a single Deki Wiki instance.

Multi-language support required several new features including a UI that updates automatically based on page language, localized templates, and language-aware search. For more information, refer here. If these features interest you, stay tuned – they will be available in our next major release (1.10).

As you might already know, all Deki Wiki functionality is exposed through a service API that can be invoked via HTTP requests. I have developed several client applications that consume the Deki Wiki API, such as the Desktop and Outlook connectors. During the development process, I was wishing for a tool to make it easy for me to view and experiment with the API… so I decided to write Apitest.exe.

Apitest.exe is a Windows application that enables users to view a list of all service features/parameters and invoke them. It works with any Dream service, but I mostly use it with the Deki Wiki service. To run Apitest:

  1. Install Dream SDK & Source
  2. Navigate to the install destination and copy srcmindtouch.apitestDefaultData.xml to redist.
  3. Launch redistmindtouch.apitest.exe
  4. Select File->Load Blueprint From… and enter your Dream service location (for Deki Wiki, enter http://<hostname>/@api/deki)
  5. You are now ready to try out any of the service features!  Note: if you’re connecting to the Deki Wiki API service, many requests require an authenticated user; it is a good idea to first login. Select Get:users/authenticate, enter your credentials, and Submit. In the results tab, you will see the headers and data returned from the request.  All subsequent requests will be made with these credentials.

I have been working on a MediaWiki to Deki Wiki converter. There have been a number of interesting bumps along the conversion path, such as handling custom MediaWiki extensions. One custom extension that kept popping up was the RSS-feed extension. Although Deki Wiki already exposes its own set of RSS-feed functions (feed.list and feed.table), the input and output behavior didn’t quite match. To maximize compatibility, I wanted the behavior to be identical to the MediaWiki RSS-feed extension. I also wanted to make it possible to easily customize the extension’s HTML output.

Having written a lot of documentation on C# extensions, I was already familiar with using C# to extend Deki Wiki functionality. C# extensions are powerful, but have a high entry barrier since they require the author to write and compile C# code. I wanted something different that was easier to crack open. As I was lamenting about the difficulty of using C# extensions, our chief architect (Steve Bjorg) made me aware of a new mechanism: DekiScript extensions. I knew nothing about them so I studied the DekiScript Extension Tutorial. DekiScript extensions consist entirely of XML and JavaScript and do not require any compilation. Within an hour, I was able to implement the RSS functionality I needed and I had something whose behavior could be easily customized!  I will be using this same mechanism to port other bits of MediaWiki behavior, such as reference citing.

You can try out the sample RSS DekiScript extension and tweak its contents to suit your needs:

* Save rssxml.txt as rss.xml.
* Open Control Panel->Service Management
* Add a new local service
* Set type=extension, SID=http://services.mindtouch.com/deki/draft/2007/12/dekiscript.
* Add the following config params: 1.) manifest=xxx, where xxx is the file location of rss.xml. 2.) api-key=xxx, where xxx is your site’s Google API key.

Happy hacking!