add SlideWindow

dev
ehlxr 2021-07-15 22:05:54 +08:00
parent e106affde0
commit cc013f3b86
1 changed files with 6 additions and 4 deletions

View File

@ -31,11 +31,10 @@ import java.util.concurrent.TimeUnit;
/**
*
* redisList
* https://www.cnblogs.com/dijia478/p/13807826.html#!comments
* https://www.cnblogs.com/dijia478/p/13807826.html#!comments
*
* @author dijia478
* @date 2020-10-13 10:53
* @author ehlxr
* @since 2021-07-15 22:04.
*/
public class SlideWindow {
/**
@ -91,6 +90,9 @@ public class SlideWindow {
}
}
/**
*
*/
public synchronized void tryAcquire() throws InterruptedException {
long nowTime = System.currentTimeMillis();
if (list.size() < count) {