Skip to content

Instantly share code, notes, and snippets.

@amitshekhariitbhu
Created July 10, 2016 16:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save amitshekhariitbhu/005fef58cfe6a169b312eef8ce95c96c to your computer and use it in GitHub Desktop.
Save amitshekhariitbhu/005fef58cfe6a169b312eef8ce95c96c to your computer and use it in GitHub Desktop.
public class DefaultExecutorSupplier{
private final PriorityThreadPoolExecutor mForBackgroundTasks;
private DefaultExecutorSupplier() {
mForBackgroundTasks = new PriorityThreadPoolExecutor(
NUMBER_OF_CORES * 2,
NUMBER_OF_CORES * 2,
60L,
TimeUnit.SECONDS,
backgroundPriorityThreadFactory
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment