azure-sdk-for-js
azure-sdk-for-js copied to clipboard
Integrity Checks
Is your feature request related to a problem? Please describe. We have multiple customers who are asking that integrity checks are performed on data transferred to and from blob storage. We have learned from an engineer on this SDK team that "the SDK itself doesn't do any integrity checks. Storage service provided integrity checks properties, you can save checksums of the content in uploading and validate the content checksum in downloading."
Describe the solution you'd like We'd like there to be integrity checks within the SDK itself
Describe alternatives you've considered We've considered saving the checksums of the properties, however, the customer leverages multiple Azure SDK's, some of which do integrity checks and others that don't so it would be inconsistent within their service.
Additional context Add any other context or screenshots about the feature request here.
@elizabethhalper If I understand you correctly, is the request that the SDK validate blob contents were uploaded successfully and provide some kind of thrown error if this doesn't happen from the upload operations?
@elizabethhalper ,
There are two levels of integrity, using uploading as an example:
- Transactional integrity check: this could be used in
PageBlobClient.uploadPages
,BlockBlobClient.stageBlock
,AppendBlobClient.appendBlock
. There's a header to set checksum for a request, storage service will compare the checksum in the header with the one it calculated from the request body and throw out an error if not match. - Whole file content integrity check: this could be used in interfaces like:
BlockBlobClient.upload
,BlockBlobClient.uploadFile
.
Customer could put a checksum for the whole file content in blob's properties. When downloading the blob, customer can check the checksum in properties with the one calculated from the downloaded content.
From customer's scenario, which way would customer need?
We use BlockBlobClient.uploadData
Could that be prioritized?
I have add the feature request into backlog, and we'd need to discuss about the feature internally.