dmccloskey opened a new pull request, #660:
URL: https://github.com/apache/arrow-rs-object-store/pull/660

   # Which issue does this PR close?
   I have not filed an issue (which I can do 😃), but this PR addresses an issue 
I was having with the `'static` lifetime constraint on the `ObjectStore` trait. 
The application that I would like to use `ObjectStore` in necessitates that 
`Arc<Dyn ObjectStore>`'s can be created on the fly as multiple object stores 
may be queried and dropped during the lifetime of the applications execution. 
   
   # Rationale for this change
    
   I have found a bit of discussion regarding lifetimes on the issues page, and 
in the Changelog, it appears that there was an effort to move `'a` to` 'static` 
to help with downstream library integrations for python. I have not looked into 
that, but the tests pass, and the proposed changes do allow for more flexible 
use of `ObjectStore`.
   
   Look forward to hearing your thoughts.
   
   # What changes are included in this PR?
   
   -  `'static` has been removed as a constraint on the `ObjectStore` trait
   - All `BoxStream<'static, Result<Bytes>>` have been changed to named 
lifetimes `BoxStream<'a, Result<Bytes>>`
   - Tests and other dependencies have been updated with named lifetimes 
accordingly.
   
   # Are there any user-facing changes?
   
   Explicit lifetimes are needed when capturing the results of `ObjectStore` 
trait methods.
   
   e.g., `Pin<Box<dyn Future<Output = Result<GetResult, object_store::Error>> + 
Send + 'static>>` is now `Pin<Box<dyn Future<Output = Result<GetResult<'a>, 
object_store::Error>> + Send + 'a>>`
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to