mirror of
https://github.com/oxen-io/session-android.git
synced 2025-02-21 10:48:26 +00:00
refactor: increase max poll time
This commit is contained in:
parent
7e14a315b9
commit
a58332a353
@ -34,7 +34,7 @@ class OpenGroupV2Poller(private val openGroups: List<OpenGroupV2>, private val e
|
|||||||
}
|
}
|
||||||
val sampleWindow = System.currentTimeMillis() - pollForNewMessagesInterval * 2
|
val sampleWindow = System.currentTimeMillis() - pollForNewMessagesInterval * 2
|
||||||
val numberInSample = receivedQueue.toList().filter { it > sampleWindow }.size.coerceAtLeast(1)
|
val numberInSample = receivedQueue.toList().filter { it > sampleWindow }.size.coerceAtLeast(1)
|
||||||
return ((2 + (50 / numberInSample / 20)*5) * 1000).toLong()
|
return ((2 + (50 / numberInSample / 20)*10) * 1000).toLong()
|
||||||
}
|
}
|
||||||
|
|
||||||
// region Settings
|
// region Settings
|
||||||
|
Loading…
x
Reference in New Issue
Block a user