Closed mdibaiee closed 7 months ago
@yunbodeng-db @andrefurlan-db @rcypher-databricks @jadewang-db any chances of a review on this? This is currently blocking us from using Databricks efficiently
@andrefurlan-db thanks! I can't merge the pull-request myself, and I think the lint and check jobs are failing for unrelated reasons (the lint errors are for other files and seem to complain because the imports are not recognised). can the pull-request be merged?
@andrefurlan-db thanks! I can't merge the pull-request myself, and I think the lint and check jobs are failing for unrelated reasons (the lint errors are for other files and seem to complain because the imports are not recognised). can the pull-request be merged?
A team member will assist you shortly. Thanks for your patience.
@kravets-levko @yunbodeng-db @mdibaiee I get 501 unimplemented response with this change, I really think this should be reverted & properly tested with the backend.
My assumption is that the file streaming is alright, but the backend doesn't actually allow data with unknown length, hence, this fails.
os.ReadFile
reads all of the content of the file into a byte array in memory, which can cause memory consumption pressure for users. Instead, anos.File
instance is itself a byte reader, and we can provide the file directly tohttp.NewRequest
so it can read the file in chunks and upload it as a stream, thus not holding the whole file in memory.