database error
[notmuch-archives.git] / 65 / 63a6eb30be1b568a14f2f31bc79ed8e4fb90fe
1 Return-Path: <glasse@cs.rpi.edu>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id 7929E431E82\r
6         for <notmuch@notmuchmail.org>; Thu,  1 Mar 2012 05:51:29 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -1.786\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.786 tagged_above=-999 required=5\r
12         tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
13         RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_SORBS_WEB=0.614] autolearn=disabled\r
14 Received: from olra.theworths.org ([127.0.0.1])\r
15         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
16         with ESMTP id GxJNqsU10Z3d for <notmuch@notmuchmail.org>;\r
17         Thu,  1 Mar 2012 05:51:29 -0800 (PST)\r
18 Received: from cliffclavin.cs.rpi.edu (cliffclavin.cs.rpi.edu\r
19  [128.113.126.25])      (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
20         (No client certificate requested)       by olra.theworths.org (Postfix) with ESMTPS\r
21  id E24D3431FAE for <notmuch@notmuchmail.org>; Thu,  1 Mar 2012 05:51:28 -0800\r
22  (PST)\r
23 X-Hash: SCtCte|8a33544e880fe0f58d8d926176accedc9741b698|60d234bb52c76d228045603c2935f730\r
24 X-Countries: Cameroon, United States\r
25 X-SMTP-From: accepted <glasse@cs.rpi.edu> [41.202.193.168] [41.202.193.168]\r
26         ([192.168.1.16]) {Cameroon}\r
27 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=cs.rpi.edu; h=\r
28         message-id:date:from:mime-version:to:cc:subject:references\r
29         :in-reply-to:content-type:content-transfer-encoding; s=default;\r
30         i=glasse@cs.rpi.edu; t=1330609887; x=1331214687; l=2291; bh=23J\r
31         Sr8hXDLxZ99JtyVXFCUrzqbE=; b=NkDOKVyXmvs6/HkMHX3N6t/Eut5gdMeG41A\r
32         8LGP6CBZAp71iv5WKEi6uVJjnT4AZKDH2o2W/hP0QmKvh1+kIlWxazJiD/9Z/xDz\r
33         RxIF0yStvOUSqxdavOpX6Fv9mHn9sRQXVwojiDOsp8LwKMt42cn0CzKVJnHTjV3N\r
34         yHeQhcCg=\r
35 DomainKey-Signature: a=rsa-sha1; c=nofws; d=cs.rpi.edu; h=message-id\r
36         :date:from:mime-version:to:cc:subject:references:in-reply-to\r
37         :content-type:content-transfer-encoding; q=dns; s=default; b=amj\r
38         mW9Cj+/qRUqi1aExMWH9ATqLZtglLeNjfsJSPGq1YzPDCeAuGHGSu8lCryL0bKfL\r
39         aMJpFkVTJyGEaprx93RHLAb51JjzcHDPc4Ns6hNBWdMGMuT883Bbl7XApwbR+LFG\r
40         wzL1s2RNwTKWfx7C/tKqo9XV02t3DD11JAwKGv4I=\r
41 X-Spam-Info: -2.7; ALL_TRUSTED,BAYES_00\r
42 X-Spam-Scanned-By: cliffclavin.cs.rpi.edu using SpamAssassin 3.2.5 (hard limit\r
43         15)\r
44 Authentication-Results: cliffclavin.cs.rpi.edu;\r
45         DKIM=neutral (none) header.from=glasse@cs.rpi.edu;\r
46         SPF=neutral (mfrom;\r
47         Mechanism '?all' matched) smtp.mail=glasse@cs.rpi.edu\r
48 X-Auth-Passed: cliffclavin.cs.rpi.edu:q21DpElp089935 Auth:glasse\r
49 X-Virus-Scanned-By: cliffclavin.cs.rpi.edu\r
50 Received: from [192.168.1.16] ([41.202.193.168]) (authenticated bits=0)\r
51         by cliffclavin.cs.rpi.edu (8.14.3/8.14.3) with ESMTP id q21DpElp089935\r
52         (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO);\r
53         Thu, 1 Mar 2012 08:51:19 -0500 (EST)\r
54         (envelope-from glasse@cs.rpi.edu)\r
55 Message-ID: <4F4F7ECA.5010206@cs.rpi.edu>\r
56 Date: Thu, 01 Mar 2012 08:51:06 -0500\r
57 From: Ethan Glasser-Camp <glasse@cs.rpi.edu>\r
58 User-Agent: Mozilla/5.0 (X11; Linux i686;\r
59         rv:8.0) Gecko/20111124 Thunderbird/8.0\r
60 MIME-Version: 1.0\r
61 To: Mark Walters <markwalters1009@gmail.com>\r
62 Subject: Re: [RFC PATCH 00/13] Modular message store code\r
63 References: <1329343326-16410-1-git-send-email-glasse@cs.rpi.edu>\r
64         <87y5s3k344.fsf@qmul.ac.uk>\r
65 In-Reply-To: <87y5s3k344.fsf@qmul.ac.uk>\r
66 Content-Type: text/plain; charset=ISO-8859-1; format=flowed\r
67 Content-Transfer-Encoding: 7bit\r
68 X-Scanned-By: MIMEDefang 2.67 on 128.113.126.25\r
69 Cc: notmuch@notmuchmail.org\r
70 X-BeenThere: notmuch@notmuchmail.org\r
71 X-Mailman-Version: 2.1.13\r
72 Precedence: list\r
73 List-Id: "Use and development of the notmuch mail system."\r
74         <notmuch.notmuchmail.org>\r
75 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
76         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
77 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
78 List-Post: <mailto:notmuch@notmuchmail.org>\r
79 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
80 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
81         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
82 X-List-Received-Date: Thu, 01 Mar 2012 13:51:29 -0000\r
83 \r
84 On 02/15/2012 07:56 PM, Mark Walters wrote:\r
85 > Obviously I have not looked at the patch set in detail yet but I have a\r
86 > quick question. Since you are allowing more general filenames anyway\r
87 > couldn't you encode mailstore in filename? Eg\r
88 > mbox://some-path[:byte-postion], or "imap://server..."\r
89 >\r
90 > This would allow lots of different types of mailstore to be used\r
91 > concurrently, and would push all the mailstore knowledge down into the\r
92 > file handling functions and away from the callers of file handling\r
93 > functions.\r
94 >\r
95 > Of course there may be lots of good reasons why this doesn't work.\r
96 >\r
97 Hi, sorry for the delay.\r
98 \r
99 As far as I can tell, currently notmuch stores message filenames in \r
100 Xapian as paths relative to the top-level maildir. I think this is done \r
101 so that the maildir can be moved and, if the .notmuch-config is updated, \r
102 mails are correctly detected and not duplicated. This would be \r
103 especially important when you're talking about changing IMAP servers or \r
104 CouchDB instances.\r
105 \r
106 If I wanted to preserve this feature, the URIs stored as filenames would \r
107 have to be relative to a given mailstore. For example, \r
108 maildir://maildir-1/INBOX/some-filename could mean the file \r
109 INBOX/some-filename in a maildir at /home/user/some-maildir. But then \r
110 this raises the two following issues:\r
111 \r
112 - How does information about mailstores -- for example, that maildir-1 \r
113 => /home/user/some-maildir -- enter the library? Do we stick all of that \r
114 information in notmuch_database_t, and then pass a reference to it in \r
115 notmuch_message_file_open? Perhaps a global \r
116 notmuch_mailstore_register(name, parameters..) registry? Or maybe a \r
117 notmuch_mailstore_info type that gets passed around similarly to the \r
118 mailstore type in this patch set?\r
119 \r
120 - Do we mandate that all the filenames in the database be updated or do \r
121 we just assume non-URI-style filenames are relative to some "default" \r
122 mailstore?\r
123 \r
124 All of which is a fancy way of saying I haven't had the time to write \r
125 the code necessary to explore this idea but think something like it will \r
126 be necessary to support the obviously-valuable feature of multiple \r
127 mailstores. Depending on your answer to the first question, I guess the \r
128 patch series might or might not be a useful starting point.\r
129 \r
130 Thanks for your feedback,\r
131 \r
132 Ethan\r
133 \r