From user-return-12264-apmail-couchdb-user-archive=couchdb.apache.org@couchdb.apache.org Sun Aug 22 13:36:25 2010 Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 51320 invoked from network); 22 Aug 2010 13:36:24 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 22 Aug 2010 13:36:24 -0000 Received: (qmail 72064 invoked by uid 500); 22 Aug 2010 13:36:23 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 71078 invoked by uid 500); 22 Aug 2010 13:36:20 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 69886 invoked by uid 99); 22 Aug 2010 13:36:19 -0000 Received: from Unknown (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 22 Aug 2010 13:36:18 +0000 X-ASF-Spam-Status: No, hits=2.9 required=10.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [209.85.215.52] (HELO mail-ew0-f52.google.com) (209.85.215.52) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 22 Aug 2010 13:35:57 +0000 Received: by ewy20 with SMTP id 20so3637237ewy.11 for ; Sun, 22 Aug 2010 06:35:36 -0700 (PDT) Received: by 10.213.113.141 with SMTP id a13mr2489935ebq.7.1282484136365; Sun, 22 Aug 2010 06:35:36 -0700 (PDT) MIME-Version: 1.0 Received: by 10.14.53.6 with HTTP; Sun, 22 Aug 2010 06:35:06 -0700 (PDT) In-Reply-To: References: From: Kenny Stone Date: Sun, 22 Aug 2010 08:35:06 -0500 Message-ID: Subject: Re: connect Ruby on Rails app to Couchdb, using library or just plain http connection ? To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=000e0cd1f99c60cfa4048e699b43 X-Virus-Checked: Checked by ClamAV on apache.org --000e0cd1f99c60cfa4048e699b43 Content-Type: text/plain; charset=ISO-8859-1 It could be helpful when you are first learning Couch to approach it this way. CouchDB really is very easy to use because its API is RESTful and pretty intuitive. JSON.parse isn't very much code getting in your way. You could use 'rest_client' as a middle ground. -- Kenny Stone Connamara Systems, LLC On Sun, Aug 22, 2010 at 6:48 AM, Jonathan Weiss wrote: > > so i need any advise from you guys, which path i need to choose, using > > plain http connection or using a library ?, to connect Rails App to > > Couch Db > > I would go for a library as you don't want to have to use Net::HTTP > and JSON parsing everywhere. Usually you want a library to abstract > this away. > There are several libraries out there for Ruby. Some are very > low-level like couchrest, some are very high-level like SimplyStored. > > Jonathan > > -- > Jonathan Weiss > http://blog.innerewut.de > http://twitter.com/jweiss > --000e0cd1f99c60cfa4048e699b43--