Dynamically change thread sleeping time to increase throughput during high load

Previously we were always blocking for 50ms no matter what, but now
we'll be dynamically adjust our block ratio depending on the current
clipboard load. In the worst case scenario when user used the clipboard only
once will go with the next sequence: 0 1(16 times) 1 2 4 8 16 32 50 50
50 and so on, until the next user request.
This commit is contained in:
Kirill Chibisov 2019-11-20 19:19:28 +03:00 committed by trimental
parent e10bbfac70
commit 7b1651a2c1
2 changed files with 38 additions and 4 deletions

View file

@ -3,6 +3,7 @@
## Unreleased
- Perform loaded data normalization for text/plain;charset=utf-8 mime type
- Fix clipboard throttling
## 0.3.5 -- 2019-09-3