Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Following sample shows simple case of executing task asynchronously without blocking current thread.
- // This is extremely handy for tasks which are not so important to block the execution of main program
- // and we do depend on their execution results.
- AsyncUtil.with(message).plan(MailSerializerUtil::toTempDir).async();
- // It's also posible to chain async tasks plans
- AsyncUtil.with(message)
- .plan(MailSerializerUtil::toTempDir)
- .plan(MailSerializerUtil::logMessage)
- .async();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement