Friday, January 18, 2013

Reading Couchbase documentation

In this post I want just highlight some wondering lines from Couchbase documentation

Couchbase

"All Couchbase SDKs automatically read and write data to the right node in a cluster. If database topology changes, the SDK responds automatically and correctly distribute read/write requests to the right cluster nodes. Similarly, if your cluster experiences server failure, SDKs will automatically direct requests to still-functioning nodes."

"For optimal performance and speed, stores most frequently used data in RAM. Persistent storage also provided to survive system downtime and for re-population of RAM."

"For example, a player making 10 game state mutations in 5 seconds, such as planting 10 flowers in 5 seconds, will be compressed by Couchbase automatically into just one queued disk mutation."

"To extend our application with new user attributes, we simply start storing additional fields at the document level. Unlike traditional relational databases, there is no need for us to have server downtime, or database migration to a new schema."


"You may wonder how effective it is to run query your view if Couchbase Server will run it on every persisted document in the database. But Couchbase Server is designed to avoid duplicate work. It will run the function on all documents once, when you first query the view. For subsequent queries on the view Couchbase Server will recompute the keys and values only for documents that have changed."

Impression

Finally I've read that Couchbase Developer's Guide 2.0
Very good example of documentation. Not the best, but very good. Many DB sites can learn from Couchbase how to write good documentation.

In some articles too many words and trivial examples (even with pictures), but sometimes amount of examples in live code is just not enough. For examples, after reading whole manual, I still don't know how to create "view" and how send it to server. Some file saving... But I know how to write functions in view and even best practices about it :)

Of course, I'm very impressed about Couchbase at all.
Ability to write map/reduce functions in JavaScript is amazing.
Auto-updating results of view is awesome.
Finally I know how my idea about select via callback function should be named - "map function" - I knew I'm reinventing the wheel :)

Tomorrow

I'm planing to add support of Couchbase to Jamm!Memory, I'm planing create there branch 2.0 (for "cas" and some other things in all cachers and to rename some methods to more familiar get/set).

I'm going to learn Ruby and try to write project in Ruby. Examples in Couchebase documentation shows that Ruby can be readable even easily than PHP.

I really think that Couchbase is the best in the NoSQL world at this moment. But maybe I just don't know all of them :)

1 comment:

  1. Thanks for this and do not hesitate to ask any question to the community if needed.
    Forums: http://www.couchbase.com/forums/
    And more information here:
    http://www.couchbase.com/wiki/display/couchbase/Home

    ReplyDelete