CouchDB: The Definitive Guide
guide.couchdb.org
guide.couchdb.org
I've not signed up for it (yet) myself; I'm concerned about a schedule conflict, but I may go ahead and do it anyway.
Even if you don't plan on using CouchDB directly, it's worth a look just to see how neatly they've implemented RESTful APIs.
Assuming you have a cluster of couchdb nodes. They all replicate, so you can spread reads and writes over the cluster. As you add nodes, read performance goes up. Initial write performance should as well.
But when you write to node N, then that data needs to be written to nodes 0-(N-1) as well. So every write goes to every node (thru replication). Since writes on CouchDB are syncronous (Eg: only one write at a time) then there is a fixed total write bandwidth on each node. Since a write on any node needs to be replicated, then, assuming the cluster is using identical machines, the total write speed of the cluster would be the same as the write speed of a single node, right?
This is probably not a problem for most cases as reads outnumber writes for web businesses. But it seems this is an area where couchDB isn't scalable.
My assessment is based on the perception that writing data coming via replication is exactly as expensive as writing data coming from the web. Replicated data goes thru the filters, and replicated data has its views recalculated as well.
there are 2 majors wins when you have this approach to a db.
1) append only memory allocation is FAST. If we were talking about writing to ram, its as simple as allocating the interval from i to i + (amount of memory needed), where i is the heap pointer
2) you don't have to deal with locks! Locks are not bad per se, but in many cases lock based data structures can lead to pain later on (just look at home much work has been done on python and linux over time in this matter).
Also, I believe that in the case that here aren't conflicting versions of the same doc in two couchdb nodes, replication is essentially bandwidth rate limited.
take the time to read up on couchdb. it may not be perfect or appropriate for everything, but it is a very very nice piece of software. And whats really awesome is that as a consequence of the append only semantics, the data loss bug they recently had was totally recoverable for those who hadn't compacted their db's! (how many db's can say that for their data loss bugs?)
http://tilgovi.github.com/couchdb-lounge/
or in a hosted Erlang version:
Has the edition changed? I'm a bit confused. I'm reading the O'Reilly eBook and it seems like what I'm reading is a draft. There are chapters seemingly missing (for instance, they described Map well enough but skipped reduce and went right into talking about Sofa without ever introducing Sofa)
However, I am reading it cover to cover and it is pretty thorough and not a bad book.
I just wonder which version I have and how it compares to the two on the new webpage.
Maybe we need a standard for book versions. Rather than just "Editions" something of a smaller increment. Like Edition/Revision.