Give recipient resolves their own thread pool.

This commit is contained in:
Greyson Parrelli 2022-05-12 16:10:36 -04:00 committed by Alex Hart
parent ef85b29ddf
commit dc095c9db4

View file

@ -55,7 +55,7 @@ public final class LiveRecipientCache {
this.warmedUp = new AtomicBoolean(false);
this.localRecipientId = new AtomicReference<>(null);
this.unknown = new LiveRecipient(context, Recipient.UNKNOWN);
this.resolveExecutor = ThreadUtil.trace(new FilteredExecutor(SignalExecutors.BOUNDED, () -> !SignalDatabase.inTransaction()));
this.resolveExecutor = ThreadUtil.trace(new FilteredExecutor(SignalExecutors.newCachedBoundedExecutor("signal-recipients", 1, 4, 15), () -> !SignalDatabase.inTransaction()));
}
@AnyThread