Creating Futures of closeable types is dangerous in general because the
underlying value may never be closed if the Future is canceled after its operation
begins. Consider replacing code that creates ListenableFutures of closeable types,
including those that pass them to this method, with #submit(ClosingCallable,
Executor) in order to ensure that resources do not leak. Or, to start a pipeline with a
ListenableFuture that doesn't create values that should be closed, use
ClosingFuture#from.
Futures of closeable types is dangerous in general because the underlying value may never be closed if theFutureis canceled after its operation begins. Consider replacing code that createsListenableFutures of closeable types, including those that pass them to this method, with#submit(ClosingCallable, Executor)in order to ensure that resources do not leak. Or, to start a pipeline with aListenableFuturethat doesn't create values that should be closed, useClosingFuture#from.