From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.1 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, NICE_REPLY_C,RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 12061 invoked from network); 5 Aug 2021 06:10:15 -0000 Received: from mx1.math.uh.edu (129.7.128.32) by inbox.vuxu.org with ESMTPUTF8; 5 Aug 2021 06:10:15 -0000 Received: from lists1.math.uh.edu ([129.7.128.208]) by mx1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1mBWa6-009Iqu-8X for ml@inbox.vuxu.org; Thu, 05 Aug 2021 01:10:14 -0500 Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by lists1.math.uh.edu with smtp (Exim 4.94) (envelope-from ) id 1mBWa5-00DFzx-Mq for ml@inbox.vuxu.org; Thu, 05 Aug 2021 01:10:13 -0500 Received: from mx2.math.uh.edu ([129.7.128.33]) by lists1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1mBWa4-00DFzs-ND for ding@lists.math.uh.edu; Thu, 05 Aug 2021 01:10:12 -0500 Received: from quimby.gnus.org ([95.216.78.240]) by mx2.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1mBWa2-00H1fU-C7 for ding@lists.math.uh.edu; Thu, 05 Aug 2021 01:10:12 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:Mime-Version:References:Message-ID:Date:Subject: From:To:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=pLeZlPYh8Kbxf7tuuawiTQTjKIrrpNTEnjHnHOV3lHc=; b=lTiFpshDcJOwbFZDDxrXmYlHWC VO21T49JdkxZAJ/acEkZo6gusbCb9rxKGidDiR2kJSU6k/HjBCalLJrHacdCTk7skJX5VpQ60Afc9 uaHHXLU72UzpN/dpXLKFOwWR6HBmUxYd7WWrZ8KJ6QmFvvvn1pKW+/kLcG6twWtzphco=; Received: from ciao.gmane.io ([116.202.254.214]) by quimby.gnus.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mBWZv-0000Ll-Qr for ding@gnus.org; Thu, 05 Aug 2021 08:10:05 +0200 Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1mBWZu-0009Qh-GR for ding@gnus.org; Thu, 05 Aug 2021 08:10:02 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: ding@gnus.org From: Pankaj Jangid Subject: Re: Does article prefetching work on IMAP? Date: Thu, 05 Aug 2021 11:39:21 +0530 Message-ID: References: <87r1fasaip.fsf@ericabrahamsen.net> <878s1h5c1e.fsf@ericabrahamsen.net> Mime-Version: 1.0 Content-Type: text/plain User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) Cancel-Lock: sha1:oZMMNZKwUjL3gvh+MOCOWRsHPp8= List-ID: Precedence: bulk Eric Abrahamsen writes: >> Eric, could you please point me to a place where this should be >> done? With some guidance, I should be able to do it. > > You mean write the code? That would be very welcome! > > Async/prefetching works by opening multiple connections to a single > server. Those connections are stored and tracked in > `nntp-connection-alist', for nntp, and `nnimap-connection-alist', for > nnimap. nnimap.el has the code to handle multiple connections, but that > functionality isn't currently used. > > The problem is in gnus-async.el, which is hard-coded to only work with > nntp. I believe the only function that would need to be changed would be > `gnus-async-wait-for-article', which currently calls > `nntp-find-connection' and `nntp-accept-process-output': these calls > would have to be abstracted to work with any server. > > Ideally we'd make *-find-connection a deffoo, and then add a > `gnus-server-find-connection' function to gnus-int.el. I'm not sure how > to handle getting rid of the `nntp-accept-process-output' call. > > Finally, you'd have to add: > > (deffoo nnimap-asynchronous-p () > t) > > to nnimap.el, in order to set the whole thing in motion. > Yes. I meant to write code. Thanks for sharing these valuable pointers. This should be okay to get started.