New code from playframeworks's Zentasks. Taken from github