-
Notifications
You must be signed in to change notification settings - Fork 750
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Derive Clone for the builders in object-store. #3419
Comments
I do not think there is any reason these structs can't implement clone. We would welcome a contribution to do so. |
@alamb unfortunately the Builders contain One option that I see is do a slight refactoring of the code where the data from the user is saved in a separate Config object, before any fallible processing is done. Then we can clone that part. Note that delta-rs is also going through some hoops here: https://github.com/delta-io/delta-rs/tree/main/rust/src/builder Let me know what you think. |
This is a relatively recent change, added in #3327, and not yet released. We could tweak the implementation of this slightly to make this simpler. I'll have a play |
Thanks @tustvold! |
Make URL parsing more strict
@alamb and @tustvold Happy New Year 2023! I tested @tustvold 's branch inside my Would it be ok to increase the scope? Many thanks! |
I think adding I think it would simply require adding
To each of the builders |
Is your feature request related to a problem or challenge? Please describe what you are trying to do.
I am using the object-store create in polars. The async code is generally contained in a small number of functions. I plan to pass around builders (eg AmazonS3Builder, MicrosoftAzureBuilder, GoogleCloudStorageBuilder) and instantiate an object-store based on the urls that are being passed in. I cannot currently use one builder more than one since they don't implement Clone.
Is there a reason why these structs are not implementing Clone?
Describe the solution you'd like
Implement (most likely derive) Clone for AmazonS3Builder, MicrosoftAzureBuilder, GoogleCloudStorageBuilder and other object_store builders.
Describe alternatives you've considered
I can recreate the struct from their fields but then I will need to maintain the code on my side.
Additional context
The text was updated successfully, but these errors were encountered: