From 1479c3a422f4727f42a06e45269bea6024be262e Mon Sep 17 00:00:00 2001 From: KayleePop <34007889+KayleePop@users.noreply.github.com> Date: Sun, 26 Aug 2018 14:33:05 -0500 Subject: Remove the concurrency limit in the browser IndexedDB chunk stores benefit from maximum concurrency --- lib/torrent.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/torrent.js b/lib/torrent.js index 0229e32..610b280 100644 --- a/lib/torrent.js +++ b/lib/torrent.js @@ -45,7 +45,8 @@ const PIPELINE_MAX_DURATION = 1 const RECHOKE_INTERVAL = 10000 // 10 seconds const RECHOKE_OPTIMISTIC_DURATION = 2 // 30 seconds -const FILESYSTEM_CONCURRENCY = 2 +// IndexedDB chunk stores used in the browser benefit from maximum concurrency +const FILESYSTEM_CONCURRENCY = process.browser ? Infinity : 2 const RECONNECT_WAIT = [ 1000, 5000, 15000 ] -- cgit v1.2.3