Return-Path: Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: (qmail 40676 invoked from network); 1 Jul 2009 09:02:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 1 Jul 2009 09:02:17 -0000 Received: (qmail 92527 invoked by uid 500); 1 Jul 2009 09:02:27 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 92448 invoked by uid 500); 1 Jul 2009 09:02:26 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 92435 invoked by uid 99); 1 Jul 2009 09:02:26 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Jul 2009 09:02:26 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jchris@gmail.com designates 209.85.218.205 as permitted sender) Received: from [209.85.218.205] (HELO mail-bw0-f205.google.com) (209.85.218.205) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Jul 2009 09:02:15 +0000 Received: by bwz1 with SMTP id 1so223753bwz.11 for ; Wed, 01 Jul 2009 02:01:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:date :x-google-sender-auth:message-id:subject:from:to:content-type :content-transfer-encoding; bh=1Z4XGgoeAzB4crkplTM/pP/ZeNP0+R4+n/gP2toFzHw=; b=d95CmPs1cF2Ql1mrZ28I3yDVhDLZk1YU73sBpMfgs5UE05cOKOr+euErMpaLsAZCE2 ygc2HMuj6nKfli8lsL6Z57iMtSwi9NQWNdcVT3eAoKYWsbaNPihJ9O9HMYn87ka+8Ibs pOhG+K2RUHjO0IoFfSzU0IH0K17+iRZ3x/3Ck= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type:content-transfer-encoding; b=JC1qSxYLfuxKT1Wza3AYlqBK9huk7v0lK2NsyuBgON+III/5EgjOBdFVZ4rd2GydGY ds65SwUNlBkcQ7l78zOcK5smGEeX+VR+eQi0yNvglygCzBf2pNNNwIw1diIRkCYzk51t /hK8eHkIz1HUo68Q6yerKVp4FRh7S2RRdm94c= MIME-Version: 1.0 Sender: jchris@gmail.com Received: by 10.204.115.130 with SMTP id i2mr7191481bkq.162.1246438914393; Wed, 01 Jul 2009 02:01:54 -0700 (PDT) Date: Wed, 1 Jul 2009 11:01:54 +0200 X-Google-Sender-Auth: 97a7ea01975cadaa Message-ID: Subject: View Performance (was Re: The 1.0 Thread) From: Chris Anderson To: dev@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org On Wed, Jul 1, 2009 at 12:26 AM, Scott Shumaker wrote: > Some of our views are invoked with stale=3Dok - but most of them can't > afford to be - if a user takes an action, typically they need to see > the results of that action if they continue on the site. > > We're using CouchDB as our main persistent storage underlying our > entire site - which has data that is pretty darn complex. =A0We have > very little back-end code - we do almost everything in run-time on the > client in Javascript - loading in complex object hierarchies and > resolving cross-object pointers. =A0So we use views very heavily, > because typically you're loading a lot of different objects at once. > > We are using the view filter patch, which helped a tiny bit - but our > data set isn't even that large yet (40k objects, admittedly many are > several K in size, or more) and the performance isn't great. =A0So I'm > definitely very concerned. =A0If we had the time to learn Erlang and the > CouchDB codebase, maybe we'd muck around to try to find optimizations. > =A0In lieu of that, we have to keep our fingers crossed for some > speedups, or failing that abandon CouchDB entirely in the next few > months. =A0:( > The slow performance you describe seems out of the ordinary. Perhaps you would benefit from upgrading Erlang or CouchDB? Is there any chance you are writing reduces which build up large data structures? How many views do you have and in how many design documents are they stored= ? Chris > Scott > > > On Tue, Jun 30, 2009 at 11:52 AM, Peter Hsu wrote: >> Scott - I don't know the details of your application. =A0What we tend to= do with our couch-backed app is rely on stale=3Dok for user-facing views. = =A0We then run a cron to update the view so that users will never get reall= y stale data. =A0This is acceptable for our application, and may be for you= rs? >> >> +1 on view performance >> +1 on erlang view server >> +1 on consolidating multiple views > --=20 Chris Anderson http://jchrisa.net http://couch.io