Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 24253431FD0 for ; Tue, 12 Jul 2011 19:23:03 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.7 X-Spam-Level: X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id B2xsdu+tBwKV for ; Tue, 12 Jul 2011 19:23:01 -0700 (PDT) Received: from dmz-mailsec-scanner-1.mit.edu (DMZ-MAILSEC-SCANNER-1.MIT.EDU [18.9.25.12]) by olra.theworths.org (Postfix) with ESMTP id D9E49431FB6 for ; Tue, 12 Jul 2011 19:23:00 -0700 (PDT) X-AuditID: 1209190c-b7c65ae00000117c-f1-4e1d018ca079 Received: from mailhub-auth-3.mit.edu ( [18.9.21.43]) by dmz-mailsec-scanner-1.mit.edu (Symantec Messaging Gateway) with SMTP id 6C.99.04476.C810D1E4; Tue, 12 Jul 2011 22:23:08 -0400 (EDT) Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) by mailhub-auth-3.mit.edu (8.13.8/8.9.2) with ESMTP id p6D2MxUA029011; Tue, 12 Jul 2011 22:22:59 -0400 Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) (authenticated bits=0) (User authenticated as amdragon@ATHENA.MIT.EDU) by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id p6D2Mwp9016080 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT); Tue, 12 Jul 2011 22:22:59 -0400 (EDT) Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.72) (envelope-from ) id 1Qgp67-0004kA-Lx; Tue, 12 Jul 2011 22:22:47 -0400 Date: Tue, 12 Jul 2011 22:22:47 -0400 From: Austin Clements To: Istvan Marko Subject: Re: Slowness (search opens every email file?) Message-ID: <20110713022247.GG25558@mit.edu> References: <20110711190721.GA5386@compy.jasonwoof.org> <20110712202459.GB15019@compy.jasonwoof.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpmleLIzCtJLcpLzFFi42IR4hTV1u1hlPUz2H/cwOLlbm2L6zdnMjsw eXxe9JTR49mqW8wBTFFcNimpOZllqUX6dglcGb1fVrMVtHBVHL72kb2B8Sd7FyMnh4SAicSC JdOhbDGJC/fWs3UxcnEICexjlHjS/IgFwtnAKLFz6U5GCOckk8T6Jw+ZIJwljBK3zzewgvSz CKhKnJvwiwXEZhPQkNi2fzlQBweHiICaxJNn+SBhZgEtia0bPzCC2MICZhJX970Cs3kFdCSO tJ2D2jadSeLryn4miISgxMmZT1hgmm/8e8kEMpNZQFpi+T8OkDCngK5Ew/9PbCC2qICKxLX9 7WwTGIVmIemehaR7FkL3AkbmVYyyKblVurmJmTnFqcm6xcmJeXmpRbqGermZJXqpKaWbGMFh Lcmzg/HNQaVDjAIcjEo8vLLxMn5CrIllxZW5hxglOZiURHkdGGT9hPiS8lMqMxKLM+KLSnNS iw8xSnAwK4nwrv8NVM6bklhZlVqUD5OS5mBREuct9/7vKySQnliSmp2aWpBaBJOV4eBQkuA9 DDJUsCg1PbUiLTOnBCHNxMEJMpwHaPg6kBre4oLE3OLMdIj8KUZFKXHeySAJAZBERmkeXC8s 7bxiFAd6RZh3M0gVDzBlwXW/AhrMBDT4tbQkyOCSRISUVANjbcvm2XWHvfY+43Lc87Va9Od2 oVqZMNZLS9quOd+2PXTWsojvwmGuhDuSvyfKa5uwKEpt8TO1L3I/7l2yTbV4c/oF5YpJkV+f afqw5XFev6jsqepfa/nxy/e8eeeXzre4fuPBzMey63Me/ZLh2nxJxnGHzHdjWXND99W9nEc6 M4qOarvvbjNUYinOSDTUYi4qTgQAEk+d4xYDAAA= Cc: Notmuch Mail X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Jul 2011 02:23:03 -0000 Quoth Istvan Marko on Jul 12 at 6:55 pm: > Austin Clements writes: > > > Istvan, did you make any progress on this patch since the last > > version? I seem to recall it just needed general cleanup (code style > > and such) and a better answer for backwards compatibility (the > > unfortunate " " thing). > > I have been using the version that encodes empty headers to " " but > another way to handle this is to simply not set a VALUE for empty > headers and then fall back to the original parsing method for these > messages. Emails without from/subject/message-id headers are not very > common so perhaps this is a good compromise. > > Below is the patch without the " " hack. Ah, clever. I was going to suggest adding another value to indicate the presence or absence of these Xapian values, but I like your solution better. The only downside I can think of is that it might not extend to other headers if we store more header values in the database in the future. I'd say this patch looks good other than coding style - Tab indentation - /* */ comments, starting with a capital letter - Space between function name and open paren - Space after comma in argument lists - Spaces around assignment operator