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
trait Lifecycle's paused function requires all its implementations to return a BoxFuture even if pausing requires no async work (e.g. because there's nothing to pause!). This function could instead return an enum with "Done" and "Pending" variants where only the latter contains a BoxFuture, allowing trivial impls to return immediately without a heap allocation.
#715 proposes to introduce a similar issue in the block::Backend trait (though masks it a bit with the use of async_trait). Several storage backends don't have any async callees in their start and stop methods and would benefit from a similar enum.