Skip to content

Commit

Permalink
Merge pull request apache#1810 from t-rana/OAK-11211
Browse files Browse the repository at this point in the history
OAK-11211: remove usage of Queues.newArrayBlockingQueue
  • Loading branch information
rishabhdaim authored Oct 21, 2024
2 parents 0a8bfa5 + e14592c commit da0ca2a
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@
import static java.util.Objects.requireNonNull;
import static org.apache.jackrabbit.guava.common.collect.Iterables.filter;
import static org.apache.jackrabbit.guava.common.collect.Iterables.size;
import static org.apache.jackrabbit.guava.common.collect.Queues.newArrayBlockingQueue;

import java.io.Closeable;
import java.lang.Thread.UncaughtExceptionHandler;
import java.util.concurrent.ArrayBlockingQueue;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.Callable;
import java.util.concurrent.Executor;
Expand Down Expand Up @@ -154,7 +154,7 @@ public BackgroundObserver(
this.executor = requireNonNull(executor);
this.exceptionHandler = requireNonNull(exceptionHandler);
this.maxQueueLength = queueLength;
this.queue = newArrayBlockingQueue(maxQueueLength);
this.queue = new ArrayBlockingQueue<>(maxQueueLength);
}

public BackgroundObserver(
Expand Down

0 comments on commit da0ca2a

Please sign in to comment.