You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
No explicit decision was ever made on whether StorageTaskCallbacks should be executed on an async thread, or if the callback needs to run on the Bukkit thread so it can interact with API functions. Given that storage tasks can be invoked synchronously or asynchronously, this is not as trivial as calling .runTask() vs .runTaskAsync() because a storage task that gets invoked synchronously might be expected to block until the provied StorageTaskCallback is complete, but using runTask() would cause a pre-mature return before all post-processing was complete. We need to also be able to detect and distinguish, either by argument or by convention, immediately invoked synchronous callback tasks and deferred, synchronous tasks.
The text was updated successfully, but these errors were encountered:
CompletableFutures are strictly better here and I don't remember why I didn't choose to use the before. Migrating Storage tasks to use CompletableFutures.
No explicit decision was ever made on whether StorageTaskCallbacks should be executed on an async thread, or if the callback needs to run on the Bukkit thread so it can interact with API functions. Given that storage tasks can be invoked synchronously or asynchronously, this is not as trivial as calling
.runTask()
vs.runTaskAsync()
because a storage task that gets invoked synchronously might be expected to block until the proviedStorageTaskCallback
is complete, but usingrunTask()
would cause a pre-mature return before all post-processing was complete. We need to also be able to detect and distinguish, either by argument or by convention, immediately invoked synchronous callback tasks and deferred, synchronous tasks.The text was updated successfully, but these errors were encountered: