couchrest_model/README.md

47 lines
1.9 KiB
Markdown
Raw Normal View History

2009-01-11 11:27:22 +01:00
# CouchRest: CouchDB, close to the metal
2008-09-07 21:54:22 +02:00
2008-10-02 19:57:13 +02:00
CouchRest is based on [CouchDB's couch.js test
library](http://svn.apache.org/repos/asf/couchdb/trunk/share/www/script/couch.js),
2008-10-02 19:57:13 +02:00
which I find to be concise, clear, and well designed. CouchRest lightly wraps
CouchDB's HTTP API, managing JSON serialization, and remembering the URI-paths
to CouchDB's API endpoints so you don't have to.
2008-09-07 21:54:22 +02:00
2009-01-16 00:05:55 +01:00
CouchRest is designed to make a simple base for application and framework-specific object oriented APIs. CouchRest is Object-Mapper agnostic, the parsed JSON it returns from CouchDB shows up as subclasses of Ruby's Hash. Naked JSON, just as it was mean to be.
2008-09-07 21:54:22 +02:00
2009-04-16 21:20:17 +02:00
Note: CouchRest only support CouchDB 0.9.0 or newer.
2009-01-11 11:27:22 +01:00
## Easy Install
2008-09-07 21:54:22 +02:00
2009-07-17 20:07:23 +02:00
$ sudo gem install couchrest
2009-01-11 11:27:22 +01:00
### Relax, it's RESTful
2008-09-07 21:54:22 +02:00
2009-07-17 20:07:23 +02:00
CouchRest rests on top of a HTTP abstraction layer using by default Herokus excellent REST Client Ruby HTTP wrapper.
Other adapters can be added to support more http libraries.
2008-09-07 21:54:22 +02:00
2009-01-11 11:27:22 +01:00
### Running the Specs
2008-09-07 21:54:22 +02:00
2008-10-02 19:57:13 +02:00
The most complete documentation is the spec/ directory. To validate your
CouchRest install, from the project root directory run `rake`, or `autotest`
(requires RSpec and optionally ZenTest for autotest support).
2008-09-07 21:54:22 +02:00
2010-01-14 02:16:16 +01:00
## Docs
API: [http://rdoc.info/projects/couchrest/couchrest](http://rdoc.info/projects/couchrest/couchrest)
2010-01-14 00:07:59 +01:00
Check the wiki for documentation and examples [http://wiki.github.com/couchrest/couchrest](http://wiki.github.com/couchrest/couchrest)
2010-01-14 01:56:21 +01:00
2010-01-14 02:16:16 +01:00
## Contact
2010-01-14 01:56:21 +01:00
Please post bugs, suggestions and patches to the bug tracker at <http://jchris.lighthouseapp.com/projects/17807-couchrest/overview>.
Follow us on Twitter: http://twitter.com/couchrest
Also, check http://twitter.com/#search?q=%23couchrest
2009-07-17 20:07:23 +02:00
## Ruby on Rails
CouchRest is compatible with rails and can even be used a Rails plugin.
However, you might be interested in the CouchRest companion rails project:
2009-07-19 09:01:07 +02:00
[http://github.com/hpoydar/couchrest-rails](http://github.com/hpoydar/couchrest-rails)