Asynchronous
With LiteCommands you can parse, suggest, and execute commands asynchronously.
When to use it?
- Database operations (SQL queries, MongoDB operations, etc.)
- Network operations (HTTP requests (APIs), socket connections, etc.)
- System IO operations (file saving/reading, etc.)
- Long-running operations (rank calculation, etc.)
How to use it?
- @Async annotation - mark a command or argument with
@Async
- CompletableFuture - use the CompletableFuture API
- Async Result API - (coming soon)