Gnus development mailing list
 help / color / mirror / Atom feed
From: Michael Welsh Duggan <mwd@cert.org>
To: ding@gnus.org
Cc: Michael Welsh Duggan <md5i@md5i.com>
Subject: Re: searching by Message-ID after copy/move; speeding things up
Date: Thu, 14 Jun 2012 16:11:55 -0400	[thread overview]
Message-ID: <tntipetwt4k.fsf@waterbuck.yellow.cert.org> (raw)
In-Reply-To: <87395x7jgn.fsf@zelenka.enovance.com> (Julien Danjou's message of "Thu, 14 Jun 2012 21:59:52 +0200")

Julien Danjou <julien@danjou.info> writes:

> On Thu, Jun 14 2012, Michael Welsh Duggan wrote:
>
>> I'm afraid not.  In some (but not all) instances the moved message
>> doesn't show up as RECENT.  (More specifically, UID SEARCH RECENT fails
>> to locate them.)  FWIW, RECENT doesn't seem to be very well specified in
>> the IMAP spec, either:
>>
>> http://mail-archives.apache.org/mod_mbox/james-server-dev/200803.mbox/%3C88f6e29a0803210110x2784101crf66e32fd96fd1b7f@mail.gmail.com%3E
>
> Too bad, I wanted to be smart. But you say sometimes it works? Maybe we
> could do RECENT, then a limited search (didn't find yet how this can be
> done) and then a total search. WDYT?

Honestly, I'd just do a limited search.  You're already doing an
EXAMINE, so you just need to parse the results to get the EXISTS count.
Then a "UID SEARCH N:* HEADER Message-ID ..."  where N is the exist
count minus a small constant.

If the limited search fails, just re-call the function with recent set
to nil.

-- 
Michael Welsh Duggan
(mwd@cert.org)



  reply	other threads:[~2012-06-14 20:11 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-14  4:42 Michael Welsh Duggan
2012-06-14  8:10 ` Julien Danjou
2012-06-14 19:51   ` Michael Welsh Duggan
2012-06-14 19:59     ` Julien Danjou
2012-06-14 20:11       ` Michael Welsh Duggan [this message]
2012-06-15 14:17         ` Julien Danjou
2012-06-15 15:11           ` Michael Welsh Duggan
2012-06-19  8:53             ` Julien Danjou
2012-06-19 15:33               ` Michael Welsh Duggan
2012-06-25 11:23                 ` Julien Danjou
2012-06-25 14:00                   ` Michael Welsh Duggan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tntipetwt4k.fsf@waterbuck.yellow.cert.org \
    --to=mwd@cert.org \
    --cc=ding@gnus.org \
    --cc=md5i@md5i.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).