Skip to content
This repository has been archived by the owner on Aug 1, 2024. It is now read-only.

Commit

Permalink
Merge pull request #753 from asorrin-msft/9.3.1_candidate
Browse files Browse the repository at this point in the history
9.3.1 candidate
  • Loading branch information
kfarmer-msft authored Aug 8, 2018
2 parents d265ac4 + 917aa86 commit 38425e7
Show file tree
Hide file tree
Showing 21 changed files with 78 additions and 40 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ public static class EncryptionConstants
public const string TableEncryptionKeyDetails = "_ClientEncryptionMetadata1";
public const string TableEncryptionPropertyDetails = "_ClientEncryptionMetadata2";
public const string AgentMetadataKey = "EncryptionLibrary";
public const string AgentMetadataValue = ".NET 9.3.0";
public const string AgentMetadataValue = ".NET 9.3.1";

}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public static class EncryptionConstants
public const string TableEncryptionKeyDetails = "_ClientEncryptionMetadata1";
public const string TableEncryptionPropertyDetails = "_ClientEncryptionMetadata2";
public const string AgentMetadataKey = "EncryptionLibrary";
public const string AgentMetadataValue = ".NET 9.3.0";
public const string AgentMetadataValue = ".NET 9.3.1";
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ namespace Microsoft.WindowsAzure.Storage.Shared.Protocol

public static class HeaderConstants
{
public static readonly string UserAgent = "Azure-Storage/9.3.0 ";
public static readonly string UserAgent = "Azure-Storage/9.3.1 ";
public const string UserAgentProductName = "Azure-Storage";
public const string UserAgentProductVersion = "9.3.0";
public const string UserAgentProductVersion = "9.3.1";
public const string PrefixForStorageHeader = "x-ms-";
public const string TrueHeader = "true";
public const string FalseHeader = "false";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("Windows Azure Storage")]
[assembly: AssemblyCopyright("Copyright © 2013 Microsoft Corp.")]
[assembly: AssemblyCopyright("Copyright © 2018 Microsoft Corp.")]
[assembly: AssemblyTrademark("Microsoft ® is a registered trademark of Microsoft Corporation.")]
[assembly: AssemblyCulture("")]

Expand All @@ -31,8 +31,8 @@
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]

[assembly: AssemblyVersion("9.3.0.0")]
[assembly: AssemblyFileVersion("9.3.0.0")]
[assembly: AssemblyVersion("9.3.1.0")]
[assembly: AssemblyFileVersion("9.3.1.0")]

[assembly: InternalsVisibleTo(
"Microsoft.WindowsAzure.Storage.Facade.Portable, PublicKey=" +
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"title": "Microsoft.WindowsAzure.Storage",
"version": "9.3.0.0",
"version": "9.3.1.0",

"authors": [ "Microsoft Corporation" ],
"description": "Azure Storage SDK for NetCore",
Expand Down
8 changes: 4 additions & 4 deletions Lib/AspNet/Microsoft.WindowsAzure.Storage/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("Microsoft Azure Storage")]
[assembly: AssemblyCopyright("Copyright © 2014 Microsoft Corp.")]
[assembly: AssemblyCopyright("Copyright © 2018 Microsoft Corp.")]
[assembly: AssemblyTrademark("Microsoft ® is a registered trademark of Microsoft Corporation.")]
[assembly: AssemblyCulture("")]

Expand All @@ -34,9 +34,9 @@
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]

[assembly: AssemblyVersion("9.3.0.0")]
[assembly: AssemblyFileVersion("9.3.0.0")]
[assembly: AssemblyInformationalVersion("9.3.0.0")]
[assembly: AssemblyVersion("9.3.1.0")]
[assembly: AssemblyFileVersion("9.3.1.0")]
[assembly: AssemblyInformationalVersion("9.3.1.0")]


[assembly: InternalsVisibleTo(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
<metadata minClientVersion="2.12">
<id>WindowsAzure.Storage</id>
<version>9.3.0</version>
<version>9.3.1</version>
<title>Windows Azure Storage</title>
<authors>Microsoft</authors>
<owners>Microsoft</owners>
Expand Down
2 changes: 1 addition & 1 deletion Lib/AspNet/Microsoft.WindowsAzure.Storage/project.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "9.3.0.0",
"version": "9.3.1.0",

"authors": [ "Microsoft Corporation" ],
"description": "Azure Storage SDK for NetCore",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public static BlobProperties GetProperties(HttpWebResponse response)
properties.ContentLanguage = response.Headers[Constants.HeaderConstants.ContentLanguageHeader];
#else
string created = response.Headers[Constants.HeaderConstants.CreationTimeHeader];
properties.Created = string.IsNullOrEmpty(created) ? (DateTimeOffset?)null : DateTimeOffset.Parse(created).ToUniversalTime();
properties.Created = string.IsNullOrEmpty(created) ? (DateTimeOffset?)null : DateTimeOffset.Parse(created, CultureInfo.InvariantCulture).ToUniversalTime();

properties.LastModified = response.LastModified.ToUniversalTime();
properties.ContentLanguage = response.Headers[HttpResponseHeader.ContentLanguage];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ public void Cancel()

internal void Wait()
{
((Task)this.internalAsyncResult).Wait();
CommonUtility.RunWithoutSynchronizationContext(() => ((Task)this.internalAsyncResult).Wait());
}
}

Expand Down Expand Up @@ -146,7 +146,7 @@ internal TResult Result
{
get
{
return ((Task<TResult>)this.internalAsyncResult).Result;
return CommonUtility.RunWithoutSynchronizationContext(() => ((Task<TResult>)this.internalAsyncResult).Result);
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,11 @@ internal static TableResult TableOperationPostProcess(TableResult result, TableO
if (resp.ContentType.Contains(Constants.JsonNoMetadataAcceptHeaderValue))
{
result.Etag = resp.Headers[Constants.HeaderConstants.EtagHeader];
ReadEntityUsingJsonParserAsync(result, operation, cmd.ResponseStream, ctx, options, System.Threading.CancellationToken.None).GetAwaiter().GetResult();
CommonUtility.RunWithoutSynchronizationContext(() => ReadEntityUsingJsonParserAsync(result, operation, cmd.ResponseStream, ctx, options, System.Threading.CancellationToken.None).GetAwaiter().GetResult());
}
else
{
ReadOdataEntityAsync(result, operation, cmd.ResponseStream, ctx, accountName, options, System.Threading.CancellationToken.None).GetAwaiter().GetResult();
CommonUtility.RunWithoutSynchronizationContext(() => ReadOdataEntityAsync(result, operation, cmd.ResponseStream, ctx, accountName, options, System.Threading.CancellationToken.None).GetAwaiter().GetResult());
}
}

Expand All @@ -127,7 +127,7 @@ internal static TableResult TableOperationPostProcess(TableResult result, TableO

internal static IList<TableResult> TableBatchOperationPostProcess(IList<TableResult> result, TableBatchOperation batch, RESTCommand<IList<TableResult>> cmd, HttpWebResponse resp, OperationContext ctx, TableRequestOptions options, string accountName)
{
return TableBatchOperationPostProcessAsync(result, batch, cmd, resp, ctx, options, accountName, System.Threading.CancellationToken.None).GetAwaiter().GetResult();
return CommonUtility.RunWithoutSynchronizationContext(() => TableBatchOperationPostProcessAsync(result, batch, cmd, resp, ctx, options, accountName, System.Threading.CancellationToken.None).GetAwaiter().GetResult());
}


Expand Down Expand Up @@ -326,11 +326,11 @@ internal static ResultSegment<TElement> TableQueryPostProcessGeneric<TElement, T

if (resp.ContentType.Contains(Constants.JsonNoMetadataAcceptHeaderValue))
{
ReadQueryResponseUsingJsonParserAsync(retSeg, responseStream, resp.Headers[Constants.HeaderConstants.EtagHeader], resolver, options.PropertyResolver, typeof(TQueryType), null, options, System.Threading.CancellationToken.None).GetAwaiter().GetResult();
CommonUtility.RunWithoutSynchronizationContext(() => ReadQueryResponseUsingJsonParserAsync(retSeg, responseStream, resp.Headers[Constants.HeaderConstants.EtagHeader], resolver, options.PropertyResolver, typeof(TQueryType), null, options, System.Threading.CancellationToken.None).GetAwaiter().GetResult());
}
else
{
List<KeyValuePair<string, Dictionary<string, object>>> results = ReadQueryResponseUsingJsonParserMetadataAsync(responseStream, System.Threading.CancellationToken.None).GetAwaiter().GetResult();
List<KeyValuePair<string, Dictionary<string, object>>> results = CommonUtility.RunWithoutSynchronizationContext(() => ReadQueryResponseUsingJsonParserMetadataAsync(responseStream, System.Threading.CancellationToken.None).GetAwaiter().GetResult());

foreach (KeyValuePair<string, Dictionary<string, object>> kvp in results)
{
Expand Down
4 changes: 2 additions & 2 deletions Lib/Common/Blob/SubStream.cs
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ public override IAsyncResult BeginRead(byte[] buffer, int offset, int count, Asy
public override int EndRead(IAsyncResult asyncResult)
{
CommonUtility.AssertNotNull("AsyncResult", asyncResult);
return ((Task<int>)asyncResult).Result;
return CommonUtility.RunWithoutSynchronizationContext(() => ((Task<int>)asyncResult).Result);
}
#endif

Expand Down Expand Up @@ -308,7 +308,7 @@ private async Task<int> ReadAsyncHelper(byte[] buffer, int offset, int count, Ca

public override int Read(byte[] buffer, int offset, int count)
{
return this.ReadAsync(buffer, offset, count).Result;
return CommonUtility.RunWithoutSynchronizationContext(() => this.ReadAsync(buffer, offset, count).Result);
}

/// <summary>
Expand Down
2 changes: 1 addition & 1 deletion Lib/Common/Shared/Protocol/Constants.cs
Original file line number Diff line number Diff line change
Expand Up @@ -923,7 +923,7 @@ static HeaderConstants()
/// <summary>
/// Specifies the value to use for UserAgent header.
/// </summary>
public const string UserAgentProductVersion = "9.3.0";
public const string UserAgentProductVersion = "9.3.1";

/// <summary>
/// Master Microsoft Azure Storage header prefix.
Expand Down
2 changes: 1 addition & 1 deletion Lib/Common/Table/ODataErrorHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public static StorageExtendedErrorInformation ReadFromStreamUsingODataLib(Stream
/// <returns>The error details.</returns>
public static StorageExtendedErrorInformation ReadAndParseExtendedError(Stream inputStream)
{
return ReadAndParseExtendedErrorAsync(inputStream, CancellationToken.None).GetAwaiter().GetResult();
return CommonUtility.RunWithoutSynchronizationContext(() => ReadAndParseExtendedErrorAsync(inputStream, CancellationToken.None).GetAwaiter().GetResult());
}

/// <summary>
Expand Down
6 changes: 3 additions & 3 deletions Lib/WindowsDesktop/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("Windows Azure Storage")]
[assembly: AssemblyCopyright("Copyright © 2013 Microsoft Corp.")]
[assembly: AssemblyCopyright("Copyright © 2018 Microsoft Corp.")]
[assembly: AssemblyTrademark("Microsoft ® is a registered trademark of Microsoft Corporation.")]
[assembly: AssemblyCulture("")]

Expand All @@ -35,8 +35,8 @@
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]

[assembly: AssemblyVersion("9.3.0.0")]
[assembly: AssemblyFileVersion("9.3.0.0")]
[assembly: AssemblyVersion("9.3.1.0")]
[assembly: AssemblyFileVersion("9.3.1.0")]

#if SIGN
[assembly: InternalsVisibleTo(
Expand Down
2 changes: 1 addition & 1 deletion Lib/WindowsDesktop/WindowsAzure.Storage.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
<metadata minClientVersion="2.12">
<id>WindowsAzure.Storage</id>
<version>9.3.0</version>
<version>9.3.1</version>
<title>Windows Azure Storage</title>
<authors>Microsoft</authors>
<owners>Microsoft</owners>
Expand Down
6 changes: 3 additions & 3 deletions Lib/WindowsPhone/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("Windows Azure Storage")]
[assembly: AssemblyCopyright("Copyright © 2013 Microsoft Corp.")]
[assembly: AssemblyCopyright("Copyright © 2018 Microsoft Corp.")]
[assembly: AssemblyTrademark("Microsoft ® is a registered trademark of Microsoft Corporation.")]
[assembly: AssemblyCulture("")]

Expand All @@ -33,8 +33,8 @@
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:

[assembly: AssemblyVersion("9.3.0.0")]
[assembly: AssemblyFileVersion("9.3.0.0")]
[assembly: AssemblyVersion("9.3.1.0")]
[assembly: AssemblyFileVersion("9.3.1.0")]

[assembly: NeutralResourcesLanguageAttribute("en-US")]

Expand Down
6 changes: 3 additions & 3 deletions Lib/WindowsPhoneRT/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("Azure Storage")]
[assembly: AssemblyCopyright("Copyright © 2013 Microsoft Corp.")]
[assembly: AssemblyCopyright("Copyright © 2018 Microsoft Corp.")]
[assembly: AssemblyTrademark("Microsoft ® is a registered trademark of Microsoft Corporation.")]
[assembly: AssemblyCulture("")]

Expand All @@ -24,8 +24,8 @@
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion("9.3.0.0")]
[assembly: AssemblyFileVersion("9.3.0.0")]
[assembly: AssemblyVersion("9.3.1.0")]
[assembly: AssemblyFileVersion("9.3.1.0")]

[assembly: NeutralResourcesLanguageAttribute("en-US")]
[assembly: ComVisible(false)]
Expand Down
6 changes: 3 additions & 3 deletions Lib/WindowsRuntime/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("Windows Azure Storage")]
[assembly: AssemblyCopyright("Copyright © 2013 Microsoft Corp.")]
[assembly: AssemblyCopyright("Copyright © 2018 Microsoft Corp.")]
[assembly: AssemblyTrademark("Microsoft ® is a registered trademark of Microsoft Corporation.")]
[assembly: AssemblyCulture("")]

Expand All @@ -26,8 +26,8 @@
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]

[assembly: AssemblyVersion("9.3.0.0")]
[assembly: AssemblyFileVersion("9.3.0.0")]
[assembly: AssemblyVersion("9.3.1.0")]
[assembly: AssemblyFileVersion("9.3.1.0")]

[assembly: ComVisible(false)]

Expand Down
34 changes: 34 additions & 0 deletions Test/ClassLibraryCommon/Blob/CloudBlobTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Threading;
Expand Down Expand Up @@ -455,6 +456,39 @@ public void CloudBlobSnapshotMetadataTask()
}
}
#endif

[TestMethod]
[Description("Ensure different regions can parse blob headers.")]
[TestCategory(ComponentCategory.Blob)]
[TestCategory(TestTypeCategory.UnitTest)]
[TestCategory(SmokeTestCategory.NonSmoke)]
[TestCategory(TenantTypeCategory.DevStore), TestCategory(TenantTypeCategory.DevFabric), TestCategory(TenantTypeCategory.Cloud)]
public void CloudBlobLocaleParsing()
{
CloudBlobContainer container = GetRandomContainerReference();
var currCulture = Thread.CurrentThread.CurrentCulture;
try
{
const string blobname = "tempfile";
container.Create();
var blockBlob = container.GetBlockBlobReference(blobname);
OperationContext context = new OperationContext();

blockBlob.UploadText("placeholder", null, null, null, context);

foreach (var culture in CultureInfo.GetCultures(CultureTypes.AllCultures))
{
Thread.CurrentThread.CurrentCulture = culture;
Assert.IsTrue(blockBlob.Exists()); // parses the header to ensure can be parsed across cultures
} // failed assertion means we never tested the parser
}
finally
{
Thread.CurrentThread.CurrentCulture = currCulture;
container.DeleteIfExists();
}
}

#region Soft-Delete

#region SYNC
Expand Down
6 changes: 5 additions & 1 deletion changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
Changes in 9.3.1:
- Blob: Fixed a bug introduced with the blob creation time property, where cultures other than en-US would fail to parse blob headers.
- Table: Fixed a bug in parsing responses from the Table service that could cause hangs or deadlocks in certain situations.

Changes in 9.3.0:
- All: Support for 2018-03-28 REST version. Please see our REST API documentation and blogs for information about the related added features. If you are using the Storage Emulator, please update to Emulator version 5.6.
- Blob: Added support for put block using a source URI and range.
Expand Down Expand Up @@ -566,4 +570,4 @@ Issues fixed in 2.0.1 :

- All: CloudStorageAccount.*Parse methods throw an exception for "UseDevelopmentStorage=true" string.
- All: StorageErrorCodeStrings class is missing.
- Blobs: ICloudBlob interface does not have GetSharedAccessSignature method.
- Blobs: ICloudBlob interface does not have GetSharedAccessSignature method.

0 comments on commit 38425e7

Please sign in to comment.