Skip to content

Commit 4bc07a1

Browse files
committed
Increase cache invalidation times for mb.cache.buf and mb.fss.
This is to avoid thrashing on sparse streams and streams that hit max msgs limits where we have to remove the first that nay be in a totally different block. Signed-off-by: Derek Collison <[email protected]>
1 parent e2752d5 commit 4bc07a1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

server/filestore.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -295,13 +295,13 @@ const (
295295
// Maximum size of a write buffer we may consider for re-use.
296296
maxBufReuse = 2 * 1024 * 1024
297297
// default cache buffer expiration
298-
defaultCacheBufferExpiration = 2 * time.Second
298+
defaultCacheBufferExpiration = 10 * time.Second
299299
// default sync interval
300300
defaultSyncInterval = 2 * time.Minute
301301
// default idle timeout to close FDs.
302302
closeFDsIdle = 30 * time.Second
303303
// default expiration time for mb.fss when idle.
304-
defaultFssExpiration = 10 * time.Second
304+
defaultFssExpiration = 2 * time.Minute
305305
// coalesceMinimum
306306
coalesceMinimum = 16 * 1024
307307
// maxFlushWait is maximum we will wait to gather messages to flush.

0 commit comments

Comments
 (0)