From 999735bad165c413b1e72376516b2a58896d0d69 Mon Sep 17 00:00:00 2001 From: Caio Saldanha Date: Thu, 28 Jan 2021 10:47:59 -0800 Subject: [PATCH 1/4] Renamed MAKeyCredential parameters --- .../src/MetricsAdvisorKeyCredential.cs | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs index b7ce4b75343e9..9265d54b2f2e1 100644 --- a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs +++ b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs @@ -46,26 +46,26 @@ internal string ApiKey /// Updates the service key. This is intended to be used when you've regenerated /// your service key and want to update long lived clients. /// - /// Key to authenticate the service against. - /// is null. - /// is empty. - public void UpdateSubscriptionKey(string key) + /// Key to authenticate the service against. + /// is null. + /// is empty. + public void UpdateSubscriptionKey(string subscriptionKey) { - Argument.AssertNotNullOrEmpty(key, nameof(key)); - SubscriptionKey = key; + Argument.AssertNotNullOrEmpty(subscriptionKey, nameof(subscriptionKey)); + SubscriptionKey = subscriptionKey; } /// /// Updates the API key. This is intended to be used when you've regenerated your /// API key and want to update long lived clients. /// - /// Key to use to authenticate the user with the Metrics Advisor service. Used to identify administrators. - /// is null. - /// is empty. - public void UpdateApiKey(string key) + /// Key to use to authenticate the user with the Metrics Advisor service. Used to identify administrators. + /// is null. + /// is empty. + public void UpdateApiKey(string apiKey) { - Argument.AssertNotNullOrEmpty(key, nameof(key)); - ApiKey = key; + Argument.AssertNotNullOrEmpty(apiKey, nameof(apiKey)); + ApiKey = apiKey; } } } From 3b56bb97545c0db5b71a70b0efc4c10019c64b55 Mon Sep 17 00:00:00 2001 From: Caio Saldanha Date: Thu, 28 Jan 2021 10:51:43 -0800 Subject: [PATCH 2/4] Updated CHANGELOG --- sdk/metricsadvisor/Azure.AI.MetricsAdvisor/CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/CHANGELOG.md b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/CHANGELOG.md index 9ad47baa79f2c..4d7e41a4dbc3c 100644 --- a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/CHANGELOG.md +++ b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/CHANGELOG.md @@ -5,6 +5,10 @@ ### New Features - Added support for AAD authentication in `MetricsAdvisorClient` and `MetricsAdvisorAdministrationClient`. +### Breaking Changes +- In `MetricsAdvisorKeyCredential`, renamed the parameter `key` to `subscriptionKey` in the method `UpdateSubscriptionKey`. +- In `MetricsAdvisorKeyCredential`, renamed the parameter `key` to `apiKey` in the method `UpdateApiKey`. + ### Key Bug Fixes - Fixed a bug in which setting `WebNotificationHook.CertificatePassword` would actually set the property `Username` instead. - Fixed a bug in which an `ArgumentNullException` was thrown when getting a `DataFeed` from the service as a Viewer. From ddd3d4d8f0dab329113958d01f5004783bf474d1 Mon Sep 17 00:00:00 2001 From: Caio Saldanha Date: Thu, 28 Jan 2021 11:11:04 -0800 Subject: [PATCH 3/4] Exported API --- .../api/Azure.AI.MetricsAdvisor.netstandard2.0.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/api/Azure.AI.MetricsAdvisor.netstandard2.0.cs b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/api/Azure.AI.MetricsAdvisor.netstandard2.0.cs index f75951db6a044..bccbc255c8c6f 100644 --- a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/api/Azure.AI.MetricsAdvisor.netstandard2.0.cs +++ b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/api/Azure.AI.MetricsAdvisor.netstandard2.0.cs @@ -216,8 +216,8 @@ public enum ServiceVersion public partial class MetricsAdvisorKeyCredential { public MetricsAdvisorKeyCredential(string subscriptionKey, string apiKey) { } - public void UpdateApiKey(string key) { } - public void UpdateSubscriptionKey(string key) { } + public void UpdateApiKey(string apiKey) { } + public void UpdateSubscriptionKey(string subscriptionKey) { } } } namespace Azure.AI.MetricsAdvisor.Administration From b1ea5e11b17a311e0b607383e312f11379511451 Mon Sep 17 00:00:00 2001 From: Caio Saldanha Date: Thu, 28 Jan 2021 14:07:33 -0800 Subject: [PATCH 4/4] Updated comments --- .../src/MetricsAdvisorKeyCredential.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs index 9265d54b2f2e1..a8139bb1b3947 100644 --- a/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs +++ b/sdk/metricsadvisor/Azure.AI.MetricsAdvisor/src/MetricsAdvisorKeyCredential.cs @@ -20,8 +20,8 @@ public class MetricsAdvisorKeyCredential /// /// Initializes a new instance of the class. /// - /// Key to use to authenticate with the Azure service. - /// Key to use to authenticate the user with the Metrics Advisor service. Used to identify administrators. + /// The subscription key to use to authenticate with the Azure service. + /// The API key to use to authenticate the user with the Metrics Advisor service. Used to identify administrators. /// or is null. /// or is empty. public MetricsAdvisorKeyCredential(string subscriptionKey, string apiKey) @@ -43,10 +43,10 @@ internal string ApiKey } /// - /// Updates the service key. This is intended to be used when you've regenerated - /// your service key and want to update long lived clients. + /// Updates the subscription key. This is intended to be used when you've regenerated + /// your subscription key and want to update long lived clients. /// - /// Key to authenticate the service against. + /// The subscription key to authenticate the service against. /// is null. /// is empty. public void UpdateSubscriptionKey(string subscriptionKey) @@ -59,7 +59,7 @@ public void UpdateSubscriptionKey(string subscriptionKey) /// Updates the API key. This is intended to be used when you've regenerated your /// API key and want to update long lived clients. /// - /// Key to use to authenticate the user with the Metrics Advisor service. Used to identify administrators. + /// The API key to use to authenticate the user with the Metrics Advisor service. Used to identify administrators. /// is null. /// is empty. public void UpdateApiKey(string apiKey)