From 9eac193c72e1380972f3589cb6b4f36b79183233 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 5 Jul 2020 23:27:37 +0000 Subject: wwwatomstream: support async blob fetch This allows -httpd to handle other requests while waiting for git to retrieve and decode blobs. We'll also break apart t/psgi_v2.t further to ensure tests run against -httpd in addition to generic PSGI testing. Using xt/httpd-async-stream.t to test against clones of meta@public-inbox.org shows a 10-12% performance improvement with the following env: TEST_JOBS=1000 TEST_CURL_OPT=--compressed TEST_ENDPOINT=new.atom --- Documentation/mknews.perl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'Documentation/mknews.perl') diff --git a/Documentation/mknews.perl b/Documentation/mknews.perl index ba049d9e..2d22d147 100755 --- a/Documentation/mknews.perl +++ b/Documentation/mknews.perl @@ -147,9 +147,10 @@ EOF } sub mime2atom { - my ($out, $astream, $mime, $ctx) = @_; - my $smsg = bless { mime => $mime }, 'PublicInbox::Smsg'; - if (defined(my $str = $astream->feed_entry($smsg))) { + my ($out, $astream, $eml, $ctx) = @_; + my $smsg = bless {}, 'PublicInbox::Smsg'; + $smsg->populate($eml); + if (defined(my $str = $astream->feed_entry($smsg, $eml))) { print $out $str or die; } } -- cgit v1.2.3-24-ge0c7