[FEATURE REQ] Content-Length -1 BlockBlobClient.upload
See original GitHub issueIs your feature request related to a problem? Please describe.
I am trying to migrate from storage sdk v8 to storage-blob sdk v12, and found that v12 does not allow -1
content-length when uploading block blobs. This is an important feature for our use cases since the size is not always known.
Describe the solution you’d like
If possible, would like the ability to provide -1
as length argument in BlockBlobClient.upload()
.
Describe alternatives you’ve considered
- Remaining on v8.
- Writing stream to temporary file before upload.
Additional context
Information Checklist Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report
- Description Added
- Expected solution specified
Thanks for consideration.
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Content-Length error in Upload File to Blob Storage
1 Answer 1 ... I believe the reason you're getting this error is because you're using incorrect upload method. upload method expects body...
Read more >BlockBlobClient class - Microsoft Learn
Uploads a browser Blob/File/ArrayBuffer/ArrayBufferView object to block blob. When buffer length lesser than or equal to 256MB, this method will use 1 upload...
Read more >@azure/storage-blob - NET
Features new. Asynchronous I/O for all operations using the async methods; HttpPipeline which enables a high degree of per-request configurability; 1-to-1 ...
Read more >Microsoft Azure REST API - Authorization Rejection due to ...
I have encountered a problem when uploading files to an Azure BLOB Storage Account. More specifically, the 'Content-Length' parameter required ...
Read more >@azure/storage-blob NPM | npm.io
You can also load separate polyfills for missed ES feature(s). ... uploadFile(); BlockBlobClient. ... npm install @azure/storage-blob@12.0.0-preview.1.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi @ryan-murphy-sc,
You actually shouldn’t have to build a BlockBlobAsyncClient to use the BlobOutputStream.
Using a BlockBlobClient you can just call one of the getOutputStream methods to obtain the associated BlobOutputStream.
Let us know if you have any issues locating the method!
Thanks for the direction @gapra-msft . I found and tried the getOutputStream method and it is working well for my use case.
I’ll close this feature request for now. Thanks for the support.