[mailmaint] Re: MULTISEARCH alternatives (was: Call for Adoption: IMAP Extensions Suggestions)
Timo Sirainen <timo@sirainen.com> Mon, 04 August 2025 09:48 UTC
Return-Path: <timo@sirainen.com>
X-Original-To: mailmaint@mail2.ietf.org
Delivered-To: mailmaint@mail2.ietf.org
Received: from localhost (localhost [127.0.0.1]) by mail2.ietf.org (Postfix) with ESMTP id D8D6A4F60382 for <mailmaint@mail2.ietf.org>; Mon, 4 Aug 2025 02:48:06 -0700 (PDT)
X-Virus-Scanned: amavisd-new at ietf.org
X-Spam-Flag: NO
X-Spam-Score: -2.099
X-Spam-Level:
X-Spam-Status: No, score=-2.099 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: mail2.ietf.org (amavisd-new); dkim=pass (1024-bit key) header.d=sirainen.com
Received: from mail2.ietf.org ([166.84.6.31]) by localhost (mail2.ietf.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IfiwQl0r0A8B for <mailmaint@mail2.ietf.org>; Mon, 4 Aug 2025 02:48:06 -0700 (PDT)
Received: from sirainen.com (mail.sirainen.com [94.237.26.55]) by mail2.ietf.org (Postfix) with ESMTP id 4E75A4F60379 for <mailmaint@ietf.org>; Mon, 4 Aug 2025 02:48:06 -0700 (PDT)
Received: from smtpclient.apple (unknown [85.156.239.150]) by sirainen.com (Postfix) with ESMTPSA id A04E82B3D5D; Mon, 4 Aug 2025 09:48:05 +0000 (UTC)
DKIM-Filter: OpenDKIM Filter v2.11.0 sirainen.com A04E82B3D5D
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=sirainen.com; s=default; t=1754300885; bh=Oh+5qFNbK8EoTDtdkKT55i/+z6/vVHEHtHtFacdoaO0=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=jWSpCJLKuBdCN+/lQTz1JrqUbymo7S491UJV96vc5qcaOYYWPMe9avpYe4q0HxfgM obbDnEaBYW+flQRhuHThN0to+tF1qnugq7TJg4kq0Cqna4Hv+GZv4dDus20x+9sli7 Llzvu1/GNIVVAmZchdwc40/oNH7Dpf83LvJzDNc4=
Content-Type: text/plain; charset="us-ascii"
Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.600.51.1.1\))
From: Timo Sirainen <timo@sirainen.com>
In-Reply-To: <60C8B6E6-6349-4B82-9B0D-8CB332665AA7@beonex.com>
Date: Mon, 04 Aug 2025 12:47:55 +0300
Content-Transfer-Encoding: quoted-printable
Message-Id: <C80F4187-E57B-433B-8D1A-6033D77E1F63@sirainen.com>
References: <60734ea8-a94a-45b6-9dda-c072fa4f9d6d@fastmail.com> <0b2d587f-d8d7-45bd-be1a-cefcc34b3331@isode.com> <0a4df11a-4f1b-419d-80ec-ad5b9112af6f@isode.com> <925F4B99-9CE4-45A6-9DEA-4AD015491812@sirainen.com> <60C8B6E6-6349-4B82-9B0D-8CB332665AA7@beonex.com>
To: Ben Bucksch <ben.bucksch@beonex.com>
X-Mailer: Apple Mail (2.3826.600.51.1.1)
Message-ID-Hash: PXZ52EIKGDERPJ43UHWOI6YH6PCGIFQB
X-Message-ID-Hash: PXZ52EIKGDERPJ43UHWOI6YH6PCGIFQB
X-MailFrom: timo@sirainen.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: mailmaint@ietf.org
X-Mailman-Version: 3.3.9rc6
Precedence: list
Subject: [mailmaint] Re: MULTISEARCH alternatives (was: Call for Adoption: IMAP Extensions Suggestions)
List-Id: Mail Maintenance <mailmaint.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/mailmaint/EzZOfOPSQd-mtl2jvzUwUHzBWIg>
List-Archive: <https://mailarchive.ietf.org/arch/browse/mailmaint>
List-Help: <mailto:mailmaint-request@ietf.org?subject=help>
List-Owner: <mailto:mailmaint-owner@ietf.org>
List-Post: <mailto:mailmaint@ietf.org>
List-Subscribe: <mailto:mailmaint-join@ietf.org>
List-Unsubscribe: <mailto:mailmaint-leave@ietf.org>
On 1. Aug 2025, at 18.48, Ben Bucksch <ben.bucksch@beonex.com> wrote: > > Timo Sirainen <timo@sirainen.com> wrote on 28. Juli 2025 17:27:19 CEST: >> ... MULTISEARCH especially are something I don't see many non-webmail clients implementing. (Also, personally I've always disliked MULTISEARCH. In Dovecot we instead just search using Virtual All mails folder.) > > Hi Timo and other experts, > > That's interesting. I'm implementing a desktop mail client and are facing that exact problem right now. > > When the user wants to search all his mail, I'm searching in the local database. The problem: It will of course contain only the full text of the emails that I already downloaded. The user might have 50 GB in their mailbox, in 500 folders, so I cannot easily download all of that on the first trial install, otherwise the first impression will be slow. That means that the local search will miss valid results, which is incorrect and bad for the user and us. > > The best solution I know of would be to make a search both locally (fast, offline, incomplete) and on the server (complete, but network delay), and then merge the results (i.e. eliminate duplicates) before display. It also has the trouble that the search results are inconsistent with what you find locally and what you find remotely, and next time the same search could give different results. But I guess it's better than no results. > Is your "dislike" of MULTISEARCH about the general principle of global search? Or is it about a design part of MULTIPART specifically? Do you have another suggestion how to do a search across all mail in all folders, which is fast enough for interactive use (ca. 1 or 2 seconds)? I If you have good guidance or tips, I would like to follow it. The way it is implemented in Open-Xchange AppSuite + Dovecot is that it finds the virtual \All folder and opens it. Then issues a regular SEARCH/SORT, and gets the original mailbox/mail with FETCH X-MAILBOX X-REAL-UID. This method seems much more flexible than MULTISEARCH since you can use any IMAP commands you want. The X-MAILBOX and X-REAL-UID aren't standard though. Also Dovecot doesn't by default expose the \All folder, and even when it is configured it's typically hidden to avoid IMAP clients unnecessarily downloading all mails twice.
- [mailmaint] Re: MULTISEARCH alternatives (was: Ca… Michael Slusarz
- [mailmaint] Call for Adoption: IMAP Extensions Su… Kenneth Murchison
- [mailmaint] Re: Call for Adoption: IMAP Extension… Mauro De Gennaro
- [mailmaint] Re: Call for Adoption: IMAP Extension… Kenneth Murchison
- [mailmaint] Re: Call for Adoption: IMAP Extension… Ben Bucksch
- [mailmaint] Re: Call for Adoption: IMAP Extension… Alexey Melnikov
- [mailmaint] Re: Call for Adoption: IMAP Extension… Mauro De Gennaro
- [mailmaint] Re: Call for Adoption: IMAP Extension… Alexey Melnikov
- [mailmaint] Re: Call for Adoption: IMAP Extension… Jeremy Harris
- [mailmaint] Re: Call for Adoption: IMAP Extension… Timo Sirainen
- [mailmaint] Re: MULTISEARCH alternatives (was: Ca… Ben Bucksch
- [mailmaint] Re: Call for Adoption: IMAP Extension… Daniel Eggert
- [mailmaint] Re: MULTISEARCH alternatives (was: Ca… Timo Sirainen
- [mailmaint] Re: Call for Adoption: IMAP Extension… Arnt Gulbrandsen
- [mailmaint] Re: MULTISEARCH alternatives (was: Ca… Ben Bucksch
- [mailmaint] Re: MULTISEARCH alternatives (was: Ca… Daniel Eggert
- [mailmaint] Re: Call for Adoption: IMAP Extension… Timo Sirainen
- [mailmaint] Re: Call for Adoption: IMAP Extension… Mauro De Gennaro
- [mailmaint] Re: Call for Adoption: IMAP Extension… Ken Murchison
- [mailmaint] IMAP Extensions Suggestions revisions Ricardo Signes
- [mailmaint] Re: IMAP Extensions Suggestions revis… Matt Diephouse
- [mailmaint] Re: IMAP Extensions Suggestions revis… Ben Bucksch
- [mailmaint] Re: IMAP Extensions Suggestions revis… N. Albert
- [mailmaint] Re: IMAP Extensions Suggestions revis… Ricardo Signes