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 0BF8E431FBC for ; Tue, 12 Jan 2010 17:24:18 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.232 X-Spam-Level: X-Spam-Status: No, score=-0.232 tagged_above=-999 required=5 tests=[AWL=2.367, BAYES_00=-2.599] autolearn=ham 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 URU-XxsN2AFi for ; Tue, 12 Jan 2010 17:24:17 -0800 (PST) Received: from clegg.madduck.net (clegg.madduck.net [193.242.105.96]) by olra.theworths.org (Postfix) with ESMTP id AF440431FAE for ; Tue, 12 Jan 2010 17:24:16 -0800 (PST) Received: from lapse.rw.madduck.net (unknown [IPv6:2404:130:0:1000:20a:e4ff:fe30:4316]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "lapse.rw.madduck.net", Issuer "CAcert Class 3 Root" (verified OK)) by clegg.madduck.net (postfix) with ESMTPS id 831CE1D4097; Wed, 13 Jan 2010 02:24:08 +0100 (CET) Received: by lapse.rw.madduck.net (Postfix, from userid 1000) id B93E926E4; Wed, 13 Jan 2010 14:24:04 +1300 (NZDT) Date: Wed, 13 Jan 2010 14:24:04 +1300 From: martin f krafft To: mailtags discussion list , notmuch discussion list Message-ID: <20100113012404.GA570@lapse.rw.madduck.net> Mail-Followup-To: mailtags discussion list , notmuch discussion list References: <20100111221909.GA30299@lapse.rw.madduck.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-ripemd160; protocol="application/pgp-signature"; boundary="zhXaljGHf11kAtnf" Content-Disposition: inline In-Reply-To: X-Motto: Keep the good times rollin' X-OS: Debian GNU/Linux squeeze/sid kernel 2.6.32-trunk-686 i686 X-Spamtrap: madduck.bogus@madduck.net X-Subliminal-Message: debian/rules! User-Agent: Mutt/1.5.20 (2009-06-14) X-Virus-Scanned: clamav-milter 0.95.3 at clegg X-Virus-Status: Clean Subject: Re: [notmuch] Idea for storing tags 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 Jan 2010 01:24:18 -0000 --zhXaljGHf11kAtnf Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable also sprach Scott Morrison [2010.01.12.1711 +1300]: > 1. synchronization of tag data with emails -- if they are in > a subfolder then it presents the issue of maintaining this > subfolder when managing emails (moving, deleting, duplicating etc) > and any .tag folder unaware clients are likely cause an breakage > in tagdata/message association. One way of doing this is to have > a global .tag folder. A global .tag folder indexed by e.g. message ID, as you state later, would probably allow for this. Or a file-per-tag design. We'd have to think carefully about pros and cons for each. When thinking about this, I always have to remind myself that we are targetting this at a design that has indexed search. If that weren't the case, searches would be incredibly expensive. Maybe a better approach would be content addressing (see below). > 2. what happens if that message is archived or moved to an > exclusively local cache -- eg. Mail.app on OS X can easily move > IMAP messages to a folder resident on the computers computers? Well, if the target can store tags, then ideally the MUA should know how to transfer them along. Maybe the right thing to do would be to use extended attributes (which are stored in the inode!), even if they may not be universally supported yet. If our solution scales, then this might lead to a significant increase in xattr adoption. > 3. what happens with duplicates of emails -- I would assume that > the message id would be the key to match the tag data to the > message. In this system a duplicate of a message could not have > a different set of tags from the original (not that this would > necessarily be desirable.) Duplicates need folders, and tags and folders are somewhat at odds with each other. I mean, you can represent a folder hierarchy with tags (and more), and if you have tags and folders, you are potentially introducing a level of confusion/ambiguity that we don't want in the first place. Maybe the ideal solution doesn't need folders anymore (and IMAP-compatible (Maildir) subfolders have always been a hack anyway). There are also two types of duplicates: copies and links. The former can diverge, the latter can't. I don't really see a reason for either. It's not like you need to copy a mail before you edit it, and I don't see a real reason for linking, assuming that the primary means of browsing will be tag-searches anyway. Duplicates always make me think of content addressing, like Git's object cache. We could store the content hash of a message in its filename, and also use the hash to index into the tag database. I think that would be much cleaner than message IDs, and would make handling true duplicates (links) much easier, while copies (diverged ex-duplicates) would also be taken care of automatically. > Your mention of potential leakage (aka inadvertent disclosure of > tag data) is real -- but only if the client used to bounce/forward > is not the one to tag the message (one would assume that if > a client can tag, it can know to exclude the tags in a bounce.) True, and it's probably the minority of people using multiple clients. But those who do might also manipulate mail with sed and use sendmail directly. I don't think we can successfully enhance RFC 5351 to make MTAs always ditch the Tags:-header. > Mail.app -- which I am pluging into does not forward headers -- ew! ;) (I think one should be able to forward pristine mails) > though it will include all headers in a bounce -- but chance are > you aren't tagging messages you are bouncing.:) That chance might well be very low. I bounce/forward-as-attachment a lot of mail from the past to make it easier for others to establish context. > The performance issue is very real -- because it means that > somehow messages have to rewritten to the IMAP server -- IMAP > doesn't have a mechanism AFAIK for updates. Not even UIDPLUS? http://wiki.dovecot.org/FeatUIDPLUS > Additionally, IMAP doesn't have a mechanism for simply replacing > one message data with another -- a new message must be written and > the old message must be deleted and the message IMAP UID will > change, and the client will have to deal with this especially if > it is cache the messages. Yes, I am experiencing this pain regularly, since I currently use a lot of message rewriting as part of my workflow =E2=80=94 one of the reasons why I'd like to find an alternative. > Also GMAIL IMAP is an issue- Yeah, I bet. Is there anyone who doesn't think that that's Google's problem, not ours, though? --=20 martin | http://madduck.net/ | http://two.sentenc.es/ =20 "there's someone in my head but it's not me." -- pink floyd, the dark side of the moon, 1972 =20 spamtraps: madduck.bogus@madduck.net --zhXaljGHf11kAtnf Content-Type: application/pgp-signature; name="digital_signature_gpg.asc" Content-Description: Digital signature (see http://martin-krafft.net/gpg/) Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iEYEAREDAAYFAktNILQACgkQIgvIgzMMSnXINACcC5HPn9BB6TLpwhMJmfau4Fa1 u8YAn0ck+gn4QN6EK1VgnV6IbjpuEJ5B =XeqW -----END PGP SIGNATURE----- --zhXaljGHf11kAtnf--