[errorprone] FileStoreAttributes#FUTURE_RUNNER: Fix corePoolSize
[ErroneousThreadPoolConstructorChecker] Thread pool size will never go beyond corePoolSize if an unbounded queue is used. see https://errorprone.info/bugpattern/ErroneousThreadPoolConstructorChecker Change-Id: Icdeaffa05301567611682da86130440f863f2ecc
This commit is contained in:
parent
13bea495c7
commit
a94e54ce87
|
@ -265,7 +265,7 @@ public static final class FileStoreAttributes {
|
||||||
* @see java.util.concurrent.Executors#newCachedThreadPool()
|
* @see java.util.concurrent.Executors#newCachedThreadPool()
|
||||||
*/
|
*/
|
||||||
private static final ExecutorService FUTURE_RUNNER = new ThreadPoolExecutor(
|
private static final ExecutorService FUTURE_RUNNER = new ThreadPoolExecutor(
|
||||||
0, 5, 30L, TimeUnit.SECONDS,
|
5, 5, 30L, TimeUnit.SECONDS,
|
||||||
new LinkedBlockingQueue<>(),
|
new LinkedBlockingQueue<>(),
|
||||||
runnable -> {
|
runnable -> {
|
||||||
Thread t = new Thread(runnable,
|
Thread t = new Thread(runnable,
|
||||||
|
|
Loading…
Reference in New Issue