Skip to content

Instantly share code, notes, and snippets.

@amitshekhariitbhu
Last active January 26, 2017 09:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save amitshekhariitbhu/52dcd765016869759cec4a72f603247f to your computer and use it in GitHub Desktop.
Save amitshekhariitbhu/52dcd765016869759cec4a72f603247f to your computer and use it in GitHub Desktop.
/*
* do some task at high priority
*/
public void doSomeTaskAtHighPriority(){
DefaultExecutorSupplier.getInstance().forBackgroundTasks()
.submit(new PriorityRunnable(Priority.HIGH) {
@Override
public void run() {
// do some background work here at high priority.
}
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment