Add a small delay between download and decode job launch
This commit is contained in:
1 parent
032563d7a4
commit
802a30e16c
1 file changed
+1
@@ -313,6 +313,7 @@ class SpiderQueenWorker(private val queen: SpiderQueen) : CoroutineScope {
|
||||
val currentJob = mDecodeJobMap[index]
|
||||
if (currentJob?.isActive != true) {
|
||||
mDecodeJobMap[index] = launch {
|
||||
delay(100)
|
||||
mFetcherJobMap[index]?.takeIf { it.isActive }?.join()
|
||||
mSemaphore.withPermit {
|
||||
doInJob(index)
|
||||
|
||||
Reference in new issue
Block a user