diff options
author | Eric Wong (Contractor, The Linux Foundation) <e@80x24.org> | 2018-04-02 00:04:55 +0000 |
---|---|---|
committer | Eric Wong (Contractor, The Linux Foundation) <e@80x24.org> | 2018-04-02 00:05:42 +0000 |
commit | 87dca6d8d5988c5eb54019cca342450b0b7dd6b7 (patch) | |
tree | a415a88759b88014d30544addbb69c5949ed76f0 /t/v2mda.t | |
parent | 3cc5ff405d9054fbf47ac44774fca4f9a72ff65a (diff) | |
download | public-inbox-87dca6d8d5988c5eb54019cca342450b0b7dd6b7.tar.gz |
In many cases, we do not care about the total number of messages. It's a rather expensive operation in SQLite (Xapian only provides an estimate). For LKML, this brings top-level /$INBOX/ loading time from ~375ms to around 60ms on my system. Days ago, this operation was taking 800-900ms(!) for me before introducing the SQLite overview DB.
Diffstat (limited to 't/v2mda.t')
-rw-r--r-- | t/v2mda.t | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -52,8 +52,8 @@ ok(PublicInbox::Import::run_die(['public-inbox-mda'], undef, $rdr), 'mda delivered a message'); $ibx = PublicInbox::Inbox->new($ibx); -my $res = $ibx->search->query(''); -my $saved = $ibx->smsg_mime($res->{msgs}->[0]); +my $msgs = $ibx->search->query(''); +my $saved = $ibx->smsg_mime($msgs->[0]); is($saved->{mime}->as_string, $mime->as_string, 'injected message'); done_testing(); |