CouchDB I have been using CouchDB recently to build some of my new projects. It’s a new schema-less, document-modelled, highly concurrent, Erlang powered “database” where you wrote map reduce functions in design views to create queries and indices. It is also very neat to bootstrap a project when you have not worked out the relational model of your database yet, due to its schema-less nature. I am still getting my head around it (coming from 15 years of SQL experience), but so far so good.

I guess one issue with CouchDB is that it’s HTTP-based interface is still not fixed, and there are quite a few differences between versions. Nor is there any upgrade utilities to convert database created in an older version to the current one, although it’s trivial to write one. Debian 5, which is my current distro of choice, is still stuck at 0.8.0 for CouchDB, when most documentation online have moved to 0.9.0. I can’t seem to be able to find ready-made CouchDB-0.9.0 Debian packages for Lenny, so I made my own from Squeeze source.

Those were built for Debian 5.

  1. Add deb-src squeeze main to /etc/apt/source.list.
  2. Run apt-get update to download the updates.
  3. Run apt-get -b source couchdb to try to build the source. It will download the source tarball, diff, etc and will attempt to build it, but will fail due to dependency.
  4. Try to build & skip dependency check. cd couchdb-0.9.0 && dpkg-buildpackage -b -uc -d
  5. You’ll end up with the .deb files above…

I’m actually putting the packages up for my own benefit so I can quickly deploy them onto my servers and have fun with its replication ability over nothing but HTTP.