Skip to content
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

Dev #33

Merged
merged 104 commits into from
Apr 12, 2013
Merged

Dev #33

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
8a143d8
update the unit tests so that the job integration tests have the right
Jan 14, 2013
624cfa2
add TaskHistoricalEvent to the queue.
Jan 14, 2013
84c6bd5
partial checkin for task historical event
Jan 15, 2013
76d9ecc
initial check in to add task historical event type.
Jan 15, 2013
8e9fdcf
Merge pull request #101 from WindowsAzure/dev
Jan 15, 2013
7d5b4b6
second checkin to support task historical events.
Jan 16, 2013
2cebbbd
Merge pull request #99 from gcheng/bettertests
Jan 21, 2013
c3cfb9f
Merge pull request #626 from gcheng/dev
Jan 21, 2013
6760316
Merge pull request #104 from WindowsAzure/dev
Jan 22, 2013
b76886a
Merge pull request #105 from gcheng/dev
Jan 22, 2013
466c43b
add job integration test for taskhistorical event
Jan 23, 2013
cc327c0
Merge branch 'dev' of https://github.com/WindowsAzure/azure-sdk-for-j…
jcookems Jan 24, 2013
455f906
Merge pull request #631 from jcookems/dev
jcookems Jan 24, 2013
f7dce4b
code review feedback.
Jan 25, 2013
0ef9985
Merge pull request #100 from gcheng/historicalevents
Jan 25, 2013
6db3cad
a missed unit test.
Jan 25, 2013
3531068
Merge pull request #106 from gcheng/historicalevents
Jan 25, 2013
04160b9
Merge pull request #632 from gcheng/dev
Jan 25, 2013
78067fc
Minor changes to address the compile-time warnings
jcookems Jan 28, 2013
7a8812e
Remove trivial TODO comments from tests
jcookems Jan 29, 2013
dda240d
Removing trivial TODO Auto-generated comments
jcookems Jan 29, 2013
40bd3e5
Replace trivial *if* statement with more useful Assert
jcookems Jan 29, 2013
269db3f
Remove "catch (InterruptedException e)" that could obscure unexpected…
jcookems Jan 29, 2013
da209fe
Merge pull request #32 from jcookems/fixWarnings
jcookems Jan 29, 2013
0413d38
Merge pull request #634 from jcookems/dev
jcookems Jan 29, 2013
4bf887e
Remove hard-coded Fiddler code in tests
jcookems Jan 29, 2013
277921f
Adding deltas to assertEquals for Date and Double, which are likely t…
jcookems Jan 29, 2013
614e96e
Merge pull request #33 from jcookems/fix205
jcookems Feb 6, 2013
eaf464c
Merge pull request #639 from jcookems/dev
jcookems Feb 6, 2013
38b3a52
[JXSCL] : Make OperationContext RequestResults thread safe,
Feb 20, 2013
f5e7c15
CR Feedback - Update tasks to provide result affinity. Now the Reque…
Feb 21, 2013
118bac1
Make BlobOutputStream use latest instead of uncommitted.
Feb 21, 2013
08648cc
Merge branch 'dev' of https://github.com/WindowsAzure/azure-sdk-for-j…
Feb 22, 2013
36ebeb4
BlobInputStream MD5 verification fix and a couple more fixes
Feb 22, 2013
940a8b6
Pull from WindowsAzure/dev
Feb 22, 2013
11b1a31
CR feedback: Update tasks to provide result affinity
Feb 25, 2013
bed1f7d
Merge branch 'dev' of https://github.com/WindowsAzure/azure-sdk-for-j…
guangyang Feb 25, 2013
19ef20c
fix the broken unit test due to nimbus server upgrade.
Feb 26, 2013
4f692bb
fix another unit test due to nimbus server upgrade.
Feb 26, 2013
77c9477
Merge pull request #107 from gcheng/unittestclean
Feb 26, 2013
ce4a3bf
Merge pull request #644 from gcheng/dev
Feb 26, 2013
742b0e2
Clean up service bus assets created as part of test at the end.
Feb 27, 2013
731245a
Merge pull request #14 from christav/sb-test-cleanup-118
Feb 27, 2013
dc4575c
Merge pull request #263 from christav/dev
Feb 27, 2013
782319d
CR feedback remove extra line
Feb 27, 2013
cba4c0d
Merge branch 'dev' of https://github.com/WindowsAzure/azure-sdk-for-j…
Feb 27, 2013
8e7fc15
Merge pull request #264 from gcheng/dev
Feb 27, 2013
c5345f2
Merge branch 'dev' of https://github.com/sozler/azure-sdk-for-java in…
Feb 28, 2013
57335fe
Update Changelog for latest fixes
Feb 28, 2013
b792da2
Merge branch 'dev' of https://github.com/WindowsAzure/azure-sdk-for-j…
Mar 1, 2013
927e31e
Merge branch 'dev' of https://github.com/WindowsAzure/azure-sdk-for-j…
Mar 1, 2013
557804b
Merge branch 'dev' of https://github.com/sozler/azure-sdk-for-java in…
Mar 1, 2013
3e422ed
fix for issue 188, broker properties mapper
Mar 6, 2013
32b0c8b
fix for issue 189, unicode issues in BrokeredMessage
Mar 6, 2013
7595d28
fix for issue 191, unicode issues in BlobOperationRestProxy.java
Mar 6, 2013
6575ffa
Merge pull request #282 from sozler/dev
Mar 6, 2013
dbff29a
update the unicode issues in HmacSHA256Sign file, issue 192#.
Mar 7, 2013
3ff10d5
fix base64 string adapter encoding issue, issue #193.
Mar 7, 2013
225aa9a
fix issue #194, unicode issue in DefaultEdmValueConverter.java
Mar 7, 2013
0ecdd94
add the missing DefaultEdmValueConverter.java file
Mar 7, 2013
171f6ad
Merge pull request #23 from gcheng/global
Mar 7, 2013
bd596d9
Merge pull request #288 from gcheng/dev
Mar 7, 2013
22961d2
Merge branch 'release' of github.com:WindowsAzure/azure-sdk-for-java …
jcookems Mar 8, 2013
6ad950a
Merge branch 'release' of https://github.com/WindowsAzure/azure-sdk-f…
Mar 8, 2013
0145416
Merge pull request #34 from jcookems/int
jcookems Mar 8, 2013
7f614ec
Merge pull request #651 from jcookems/dev
jcookems Mar 8, 2013
48ca51e
Merge pull request #9 from jcookems/int
jcookems Mar 8, 2013
492299f
Merge pull request #290 from jcookems/release
jcookems Mar 8, 2013
398e721
Updating POM version
jcookems Mar 8, 2013
11ec4a9
Merge pull request #291 from jcookems/release
jcookems Mar 8, 2013
5fc77e0
Merge pull request #289 from joeg/devMerge
Mar 9, 2013
6aea867
Merge branch 'release' of https://github.com/WindowsAzure/azure-sdk-f…
Mar 9, 2013
b6928e0
Merge branch 'release' of https://github.com/WindowsAzure/azure-sdk-f…
guangyang Mar 11, 2013
baff388
update changelog for 0.4.1
guangyang Mar 11, 2013
1944273
update change log and readme.md based on PR review feedback
guangyang Mar 11, 2013
dd74ec3
fixing policheck issues
guangyang Mar 11, 2013
f0d6ca3
fixing policheck issues
guangyang Mar 11, 2013
e92621b
Merge pull request #292 from guangyang/release
guangyang Mar 11, 2013
be09f31
throw exception when you create or update null message.
Mar 11, 2013
bff956b
Merge pull request #24 from gcheng/global
Mar 12, 2013
ab6b488
Merge pull request #293 from gcheng/dev
Mar 12, 2013
fb2b701
Merge pull request #295 from WindowsAzure/release
Mar 14, 2013
75d7a8c
Merge pull request #296 from WindowsAzure/master
Mar 14, 2013
c8561a2
fix the global date parsing issue.
Mar 22, 2013
cce6e7c
fix the javadoc documentation issue.
Mar 22, 2013
ff2397d
Merge branch 'dev' of https://github.com/gcheng/azure-sdk-for-java in…
Mar 22, 2013
42d86ee
Merge pull request #27 from WindowsAzure/dev
Mar 22, 2013
e6b0f5b
Merge branch 'dev' of https://github.com/gcheng/azure-sdk-for-java in…
Mar 22, 2013
dcd468f
Merge pull request #25 from gcheng/global
Mar 22, 2013
087ec84
Merge pull request #26 from gcheng/packagedoc
Mar 22, 2013
405d480
Merge pull request #300 from gcheng/dev
Mar 22, 2013
dcc2a07
Updating version number to 0.4.2
jcookems Mar 25, 2013
81f1269
Merge pull request #302 from jcookems/dev
jcookems Mar 25, 2013
3e76780
fix the failure of a few global unit tests.
Mar 25, 2013
38a9727
Merge pull request #28 from gcheng/global
Mar 25, 2013
9d7c79c
Merge pull request #304 from gcheng/dev
Mar 25, 2013
9998b88
fix unit test failures due to media service upgrade.
Mar 27, 2013
fd3107b
Merge pull request #29 from gcheng/nimbusfailure
Mar 27, 2013
b4b7fb5
Merge pull request #312 from gcheng/dev
Mar 27, 2013
44e2421
Merge pull request #13 from gcheng/rebindcontentkey
Apr 9, 2013
5740210
Merge pull request #319 from gcheng/dev
Apr 9, 2013
90b28e1
Merge pull request #30 from gcheng/rebindcontentkey
Apr 11, 2013
f85f1e0
Merge pull request #321 from gcheng/dev
Apr 11, 2013
11992bb
Merge pull request #32 from WindowsAzure/dev
Apr 12, 2013
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions ChangeLog.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,22 @@
2013.1.18 Version 0.4.0
2013.03.12 Version 0.4.1
* Added "Azure-SDK-For-Java/<version>" To User-Agent HTTP header
* Added connection string support for Service Bus
* Added new methods to break lease for Storage Blob which doesn't require a lease id and returns the result as an object. Deprecated the old breakLease() methods.
* Added a new method to get the historical events for Media Services
* Fixed Storage Table encoding issue for special characters
* BlobOutputStream now commits block list using LATEST instead of UNCOMMITTED
* Added RequestResult to StorageEvents
* Fixed issue when accessing OperationContext RequestResults
* Fixed the return value of BlobInputStream.read
* Fixed CloudPageBlob.downloadPageRanges to retrieve the blob length
* Fixed MD5 validation in BlobInputStream
* Return ETag in TableResult not only for Insert but also for other operations

2013.01.18 Version 0.4.0
* Added support for Windows Azure Media Services
* Updated dependencies to non-beta stable versions
* Add a Sending Request Event to OperationContext in Storage Client code
* Fix a bug in the STorage client in blob download resume for blobs greater than 2GB
* Added a Sending Request Event to OperationContext in Storage Client code
* Fixed a bug in the Storage client in blob download resume for blobs greater than 2GB

2012.10.29 Version 0.3.3
* In the blob client, fixed a bug which allows users to call write APIs on a blob snapshot reference
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ within your project you can also have them installed by the Java package manager
<dependency>
<groupId>com.microsoft.windowsazure</groupId>
<artifactId>microsoft-windowsazure-api</artifactId>
<version>0.4.0</version>
<version>0.4.2</version>
</dependency>

##Minimum Requirements
Expand Down
4 changes: 2 additions & 2 deletions microsoft-azure-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.microsoft.windowsazure</groupId>
<artifactId>microsoft-windowsazure-api</artifactId>
<version>0.4.0</version>
<version>0.4.2</version>
<packaging>jar</packaging>

<name>Microsoft Windows Azure Client API</name>
Expand Down Expand Up @@ -175,7 +175,7 @@
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.8</version>
<configuration>
<excludePackageNames>*.implementation.*;*.utils.*;com.microsoft.schemas._2003._10.serialization</excludePackageNames>
<excludePackageNames>*.implementation.*;*.utils.*;com.microsoft.schemas._2003._10.serialization;*.blob.core.storage</excludePackageNames>
<bottom><![CDATA[<code>/**
<br/>* Copyright Microsoft Corporation
<br/>*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
* Copyright Microsoft Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.microsoft.windowsazure.serviceruntime;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
* Copyright Microsoft Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.microsoft.windowsazure.serviceruntime;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,11 @@ public final class BlobInputStream extends InputStream {
*/
private boolean validateBlobMd5;

/**
* Holds the Blob MD5.
*/
private final String retrievedContentMD5Value;

/**
* Holds the reference to the current buffered data.
*/
Expand Down Expand Up @@ -161,11 +166,11 @@ protected BlobInputStream(final CloudBlob parentBlob, final AccessCondition acce

final HttpURLConnection attributesRequest = this.opContext.getCurrentRequestObject();

final String retrievedContentMD5Value = attributesRequest.getHeaderField(Constants.HeaderConstants.CONTENT_MD5);
this.retrievedContentMD5Value = attributesRequest.getHeaderField(Constants.HeaderConstants.CONTENT_MD5);

// Will validate it if it was returned
this.validateBlobMd5 = !options.getDisableContentMD5Validation()
&& !Utility.isNullOrEmpty(retrievedContentMD5Value);
&& !Utility.isNullOrEmpty(this.retrievedContentMD5Value);

// Validates the first option, and sets future requests to use if match
// request option.
Expand Down Expand Up @@ -395,8 +400,17 @@ public boolean markSupported() {
@DoesServiceRequest
public int read() throws IOException {
final byte[] tBuff = new byte[1];
this.read(tBuff, 0, 1);
return tBuff[0];
final int numberOfBytesRead = this.read(tBuff, 0, 1);

if (numberOfBytesRead > 0) {
return tBuff[0] & 0xFF;
}
else if (numberOfBytesRead == 0) {
throw new IOException("Unexpected error. Stream returned unexpected number of bytes.");
}
else {
return -1;
}
}

/**
Expand Down Expand Up @@ -519,13 +533,13 @@ private synchronized int readInternal(final byte[] b, final int off, int len) th
if (this.currentAbsoluteReadPosition == this.streamLength) {
// Reached end of stream, validate md5.
final String calculatedMd5 = Base64.encode(this.md5Digest.digest());
if (!calculatedMd5.equals(this.parentBlobRef.getProperties().getContentMD5())) {
if (!calculatedMd5.equals(this.retrievedContentMD5Value)) {
this.lastError = Utility
.initIOException(new StorageException(
StorageErrorCodeStrings.INVALID_MD5,
String.format(
"Blob data corrupted (integrity check failed), Expected value is %s, retrieved %s",
this.parentBlobRef.getProperties().getContentMD5(), calculatedMd5),
this.retrievedContentMD5Value, calculatedMd5),
Constants.HeaderConstants.HTTP_UNUSED_306, null, null));
this.streamFaulted = true;
throw this.lastError;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ private synchronized void dispatchWrite(final int writeLength) throws IOExceptio
if (this.streamType == BlobType.BLOCK_BLOB) {
final CloudBlockBlob blobRef = (CloudBlockBlob) this.parentBlobRef;
final String blockID = Base64.encode(Utility.getBytesFromLong(this.blockIdSequenceNumber++));
this.blockList.add(new BlockEntry(blockID, BlockSearchMode.UNCOMMITTED));
this.blockList.add(new BlockEntry(blockID, BlockSearchMode.LATEST));

worker = new Callable<Void>() {
@Override
Expand Down
Loading