refactor: increase max poll time

This commit is contained in:
jubb 2021-04-30 16:57:06 +10:00
parent 7e14a315b9
commit a58332a353
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ class OpenGroupV2Poller(private val openGroups: List<OpenGroupV2>, private val e
}
val sampleWindow = System.currentTimeMillis() - pollForNewMessagesInterval * 2
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