MarkLogic 4 - Initial thoughts 18 Oct 2008

Last week I upgraded our development server to MarkLogic 4.0.1. The actual installation process was pretty simple – uninstall 3, install 4. Thankfully it kept all the databases, app servers and configuration. The only delay was reindexing the content, which took about 4 days for a 160gb database (3.3m fragments).

ML 4 now supports XQuery 1.0, but automatically sets existing app servers to use 0.9 to maintain compatibility. There were still a number of small code changes I had to make to get our apps running, seemingly because even in 0.9 mode it is still stricter with parsing/executing xquery code:

declare function get-title() as xs:string {
    <title>the <b>title</b></title>
};
<x>{getTitle()}</x>

returns..

ML 3.2.8: <x><title>the <b>title</b></title></x>
ML 4.0.1: <x>the title</x>

No argument, ML 4 has it right, but it did break my app and took a while to figure out.

ML 4 has some interesting new features – XQuery 1.0, the geospacial stuff looks cool, and the forest level failover is something we’re going to use straight away. I was a bit disappointed they didn’t take the chance to address some other areas: