changeset 8182:4bfe2c1c375f HEAD

Mail cache file: Changed lock timeout to just 2 seconds. It's better to not update cache than waste a lot of time waiting for a lock. Also increased staleness timeout to 5 minutes - it's safer that way and with the reduced lock timeout doesn't matter as much.
author Timo Sirainen <tss@iki.fi>
date Tue, 09 Sep 2008 18:34:29 +0300
parents 5c0c674eae1a
children da6fd72f8103
files src/lib-index/mail-cache-private.h
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-index/mail-cache-private.h	Tue Sep 09 18:30:23 2008 +0300
+++ b/src/lib-index/mail-cache-private.h	Tue Sep 09 18:34:29 2008 +0300
@@ -36,8 +36,8 @@
 /* When allocating space for transactions, don't use blocks larger than this. */
 #define MAIL_CACHE_MAX_RESERVED_BLOCK_SIZE (1024*512)
 
-#define MAIL_CACHE_LOCK_TIMEOUT 120
-#define MAIL_CACHE_LOCK_CHANGE_TIMEOUT 60
+#define MAIL_CACHE_LOCK_TIMEOUT 2
+#define MAIL_CACHE_LOCK_CHANGE_TIMEOUT 300
 
 #define CACHE_RECORD(cache, offset) \
 	((const struct mail_cache_record *) \