couchbase/couchbase-ruby-model — pull request #1 by stakach (2012-11-24 05:55:38+00:00)
Title: Added as_json method for rails JSON responses

Added as_json method for rails JSON responses

Allows the following to occur in a controller:
`render :json => model.as_json(:except => :some_secret_field)`

Where `model` is a `Couchbase::Model`

I've also written a deterministic id generator based on the counter id pattern at http://couchbasemodels.com/ if you are interested in including it?
Supports up to 340282366920938463426481119284349108225 documents per cluster before manual intervention is required. Has built in XDCR support to avoid any id clashes too.