[PATCH v2 0/3] notmuch insert failure paths and post-insert hook
authorJani Nikula <jani@nikula.org>
Sun, 28 Sep 2014 14:40:56 +0000 (17:40 +0300)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 18:04:47 +0000 (10:04 -0800)
b0/350c2725588423e466833d4b1b6f920b58f09e [new file with mode: 0644]

diff --git a/b0/350c2725588423e466833d4b1b6f920b58f09e b/b0/350c2725588423e466833d4b1b6f920b58f09e
new file mode 100644 (file)
index 0000000..fcb9f4f
--- /dev/null
@@ -0,0 +1,91 @@
+Return-Path: <jani@nikula.org>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id BCF5C431FC2\r
+       for <notmuch@notmuchmail.org>; Sun, 28 Sep 2014 07:41:12 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.7\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
+       tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id 2SYfkbMVe9VA for <notmuch@notmuchmail.org>;\r
+       Sun, 28 Sep 2014 07:41:05 -0700 (PDT)\r
+Received: from mail-we0-f171.google.com (mail-we0-f171.google.com\r
+       [74.125.82.171]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id C0D82431FAE\r
+       for <notmuch@notmuchmail.org>; Sun, 28 Sep 2014 07:41:04 -0700 (PDT)\r
+Received: by mail-we0-f171.google.com with SMTP id k48so11635014wev.30\r
+       for <notmuch@notmuchmail.org>; Sun, 28 Sep 2014 07:41:03 -0700 (PDT)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+       d=1e100.net; s=20130820;\r
+       h=x-gm-message-state:from:to:cc:subject:date:message-id;\r
+       bh=3kQEvliXIuPTYwi1TemmLC/wpS9if53/BvqewbUfAf4=;\r
+       b=VxEKK063Efzf1hlBQrocoQY0enRzD9/J9Flj8wvLPna1QX9A8yYo+Ey2pnOJPpqs1h\r
+       3D0l6ZGawbhQB3ja6D1biO8e/CwlOb8eMOc+mZExwAc0lvexAZS6KLnjxYs7VJ0zaK2i\r
+       SrKbGFlbAFOyq9+f1FOYcyauabOv27IPyj/08gT8HZL0hpFKk2nz/SRCwtDG7EIgCuvh\r
+       WV9LOHELs31fJCHPnc/1du5atlgXX/cY23QDgj5RWsG0vfAFWtFvQ2XuSI4xmHul83kv\r
+       OABcwEcIFEVSTS1/1lQNM+MNeRWoCAKD4hyhj/0Q6pJwmhb/3siqgEegc6OQ7d2jM5fy\r
+       DPbg==\r
+X-Gm-Message-State:\r
+ ALoCoQl1FQCgtUPqm2IdYFJvewnu9vbleC1NZPocviNNMytlOIzu/ZYV1N80ifALK70m3DtOvihM\r
+X-Received: by 10.194.93.7 with SMTP id cq7mr38319913wjb.58.1411915262391;\r
+       Sun, 28 Sep 2014 07:41:02 -0700 (PDT)\r
+Received: from localhost (dsl-hkibrasgw2-58c36c-245.dhcp.inet.fi.\r
+       [88.195.108.245])\r
+       by mx.google.com with ESMTPSA id pn5sm12715088wjc.4.2014.09.28.07.41.01\r
+       for <multiple recipients>\r
+       (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\r
+       Sun, 28 Sep 2014 07:41:01 -0700 (PDT)\r
+From: Jani Nikula <jani@nikula.org>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH v2 0/3] notmuch insert failure paths and post-insert hook\r
+Date: Sun, 28 Sep 2014 17:40:56 +0300\r
+Message-Id: <cover.1411914914.git.jani@nikula.org>\r
+X-Mailer: git-send-email 2.1.0\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Sun, 28 Sep 2014 14:41:12 -0000\r
+\r
+This is v2 of the final three patches of [1]. The failure paths have\r
+been improved further still, with some new warning messages on any\r
+cleanup errors as well. Man pages have been updated.\r
+\r
+Tests are still lacking. The post-insert hook should be simple, but I\r
+haven't had a sudden outburst of creativity in figuring out how to test\r
+all the fail scenarios.\r
+\r
+BR,\r
+Jani.\r
+\r
+\r
+[1] id:cover.1411379395.git.jani@nikula.org\r
+\r
+Jani Nikula (3):\r
+  cli/insert: add fail path to add_file_to_database\r
+  cli/insert: require succesful message indexing for success status\r
+  cli/insert: add post-insert hook\r
+\r
+ doc/man1/notmuch-insert.rst |  26 ++++++--\r
+ doc/man5/notmuch-hooks.rst  |  11 ++++\r
+ notmuch-insert.c            | 140 +++++++++++++++++++++++++++++++-------------\r
+ test/T070-insert.sh         |   2 +-\r
+ 4 files changed, 132 insertions(+), 47 deletions(-)\r
+\r
+-- \r
+2.1.0\r
+\r