Blogroll

Meta

Day: January 20, 2009

I just learned about the Paxos algorithm. I think we might be able to use it to create a fully distributed version of ZODB. I found a document that explains Paxos in simple terms. Now I’m interested in learning about any ideas and software that might support integration of Paxos into ZODB. I would also like to know how much interest people have in such a project.

I think ZODB’s transaction layer already implements a sort of squashed version of Paxos, but it’s not currently possible to separate the pieces to make it distributed. To me, “distributed ZODB” means multiple servers accept writes while assuring consistency at all times. I also require sub-millisecond response timing on the majority of read operations, since that is what ZODB applications have come to rely upon. I suspect the speed requirement disqualifies systems like CouchDB.

I simply posted a patched ZODB3 source distribution on a virtual-hosted server. The first tarball, “ZODB3-3.8.1-polling-serial.tar.gz”, includes both the invalidation polling patch and the framework I created for plugging in data serialization formats other than pickles, but in the near future I plan to also post distributions with just the polling patch and some eggs for Windows users.

It would not make sense for me to post the patched tarballs and eggs on PyPI because I don’t want people to pull these patched versions accidentally. Pulling these needs to be an explicit step.

Thanks to setuptools and zc.buildout, it turns out that creating a Python code distribution server is a piece of cake. The buildout process scans the HTML pages on distribution servers for <a> links. Any link that points to a tarball or egg with a version number is considered a candidate. A static web site can easily fulfill these requirements. I imagine it gets deeper than that, but for now, that’s all I need.

To use this tarball, buildout.cfg just needs to include lines something like:

It took a while to find this solution because, upon encountering the need to distribute patched eggs, I guessed it would be difficult to set up and maintain my own package distribution server. I also guessed setuptools had no support for patches in its versioning scheme. I’m glad I was completely wrong.

By the way, Ian suggested pip as a solution, but I don’t yet see how it helps. I am interested. I hope to see more of pip on Ian’s great blog.