Skip to content
This repository was archived by the owner on Jul 19, 2024. It is now read-only.

Commit 4c5ffa1

Browse files
author
Josh Friedman
committed
Fixed a bug related to uploadFromMultiStream
1 parent 09c67c2 commit 4c5ffa1

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

ChangeLog.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
2017.06.21 Version 5.3.1
2+
* Fixed a bug in specific upload case for block blobs. This only affects uploads greater than the max put blob threshold, that have increased the streamWriteSizeInBytes beyond the 4 MB and storeBlobContentMD5 has been disabled.
3+
14
2017.06.13 Version 5.3.0
25
* Fixed a bug where the transactional MD5 check would fail when downloading a range of blob or file and the recovery action is performed on a subsection of the range.
36
* Fixed leaking connections for table requests.

microsoft-azure-storage-test/src/com/microsoft/azure/storage/blob/CloudBlockBlobTests.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1057,8 +1057,9 @@ public void testLargeBlobUploadFromStreamAccessConditionTest() throws URISyntaxE
10571057
srcStream = BlobTestHelper.getRandomDataStream(length);
10581058
blockBlobRef.upload(srcStream, length, accessCondition, options, null);
10591059
}
1060-
catch (StorageException ex)
1060+
catch (IOException e)
10611061
{
1062+
StorageException ex = (StorageException)e.getCause();
10621063
assertEquals(412, ex.getHttpStatusCode());
10631064
assertEquals(StorageErrorCodeStrings.CONDITION_NOT_MET, ex.getErrorCode());
10641065
}

microsoft-azure-storage/src/com/microsoft/azure/storage/blob/CloudBlockBlob.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -733,6 +733,11 @@ public byte[] getByteArray() {
733733
|| options.getStoreBlobContentMD5()
734734
|| descriptor.getLength() == -1;
735735

736+
// there are two known issues with the uploadFromMultiStream logic
737+
// 1. The same block ids are being used for each batch of uploads.
738+
// 2. When using a bufferedInputStream and the size of the stream being uploaded exceeds Integer.MAX_VALUE,
739+
// a NegativeArraySizeException is thrown when attempting to skip past the 1 GB mark.
740+
useOpenWrite = true;
736741
if (useOpenWrite) {
737742
final BlobOutputStream writeStream = this.openOutputStream(accessCondition, options, opContext);
738743
try {

0 commit comments

Comments
 (0)