@Override
    protected void afterExecute(Runnable r, Throwable t) {
        super.afterExecute(r, t);
        if (t == null && r instanceof Future<?>) {
            Future<?> future = (Future<?>) r;
            if (future.isDone() && !future.isCancelled()) {
                try {
                    future.get();
                } catch (InterruptedException e) {
                    uncaughtThrowableStrategy.handle(e);
                } catch (ExecutionException e) {
                    uncaughtThrowableStrategy.handle(e);
                }
            }
        }
    }
Constructor to build a fixed thread pool with the given pool size using
{@link DefaultThreadFactory}.

@param poolSize The number of threads.
@param uncaughtThrowableStrategy Dictates how the pool should handle uncaught and unexpected throwables
                                 thrown by Futures run by the pool.
core/src/main/java/com/bumptech/glide/load/engine/executor/FifoPriorityThreadPoolExecutor.java