Enable compressed connections to the IMAP server
Added the configuration setting usecompression for the IMAP repositories. When enabled, the data from and to the IMAP server is compressed. Signed-off-by: Eygene Ryabinkin <rea@codelabs.ru>
This commit is contained in:
parent
0c4fe6bada
commit
0903428fda
@ -9,6 +9,7 @@ OfflineIMAP v6.5.6 (YYYY-MM-DD)
|
||||
===============================
|
||||
|
||||
* Add knob to invoke folderfilter dynamically on each sync (GitHub#73)
|
||||
* Add knob to apply compression to IMAP connections (Abdó Roig-Maranges)
|
||||
|
||||
|
||||
OfflineIMAP v6.5.5 (2013-10-07)
|
||||
|
@ -479,6 +479,11 @@ remoteuser = username
|
||||
# idlefolders = ['INBOX', 'INBOX.Alerts']
|
||||
#
|
||||
|
||||
# OfflineIMAP can use a compressed connection to the IMAP server.
|
||||
# This can result in faster downloads for some cases.
|
||||
#
|
||||
#usecompression = yes
|
||||
|
||||
# OfflineIMAP can use multiple connections to the server in order
|
||||
# to perform multiple synchronization actions simultaneously.
|
||||
# This may place a higher burden on the server. In most cases,
|
||||
|
@ -422,6 +422,10 @@ class IMAPServer:
|
||||
self.passworderror = str(e)
|
||||
raise
|
||||
|
||||
# Enable compression
|
||||
if self.repos.getconfboolean('usecompression', 0):
|
||||
imapobj.enable_compression()
|
||||
|
||||
# update capabilities after login, e.g. gmail serves different ones
|
||||
typ, dat = imapobj.capability()
|
||||
if dat != [None]:
|
||||
|
Loading…
Reference in New Issue
Block a user