Skip to content

Commit 8cafecb

Browse files
authored
hotfix for Azure Active Directory Admin set (Azure#16806)
* hotfix for Azure Active Directory Admin set * updating changelog
1 parent 58318c7 commit 8cafecb

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

src/Sql/Sql/ChangeLog.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
- Additional information about change #1
1919
-->
2020
## Upcoming Release
21+
* Hotfix for Azure Active Directory Admin
22+
- AzureSqlServerActiveDirectoryAdministratorAdapter and AzureSqlInstanceActiveDirectoryAdministratorAdapter both used AzureEnvironment.Endpoint.AzureEnvironment.Endpoint.Graph instead of AzureEnvironment.ExtendedEndpoint.MicrosoftGraphUrl
2123

2224
## Version 3.7.0
2325
* Added `ZoneRedundant` parameter to `New-AzSqlDatabaseCopy`, `New-AzSqlDatabaseSecondary` and `Restore-AzSqlDatabase` to enable zone redundant copy, geo secondary and PITR support for hyperscale databases

src/Sql/Sql/InstanceActiveDirectoryAdministrator/Services/AzureSqlInstanceActiveDirectoryAdministratorAdapter.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public MicrosoftGraphClient MicrosoftGraphClient
5454
{
5555
if (_microsoftGraphClient == null)
5656
{
57-
_microsoftGraphClient = AzureSession.Instance.ClientFactory.CreateArmClient<MicrosoftGraphClient>(Context, AzureEnvironment.Endpoint.Graph);
57+
_microsoftGraphClient = AzureSession.Instance.ClientFactory.CreateArmClient<MicrosoftGraphClient>(Context, AzureEnvironment.ExtendedEndpoint.MicrosoftGraphUrl);
5858
_microsoftGraphClient.TenantID = Context.Tenant.Id;
5959
}
6060
return _microsoftGraphClient;
@@ -315,7 +315,7 @@ protected Guid GetTenantId()
315315
{
316316
var tenantIdStr = Context.Tenant.Id.ToString();
317317
string adTenant = Context.Environment.GetEndpoint(AzureEnvironment.Endpoint.AdTenant);
318-
string graph = Context.Environment.GetEndpoint(AzureEnvironment.Endpoint.Graph);
318+
string graph = Context.Environment.GetEndpoint(AzureEnvironment.ExtendedEndpoint.MicrosoftGraphUrl);
319319
var tenantIdGuid = Guid.Empty;
320320

321321
if (string.IsNullOrWhiteSpace(tenantIdStr) || !Guid.TryParse(tenantIdStr, out tenantIdGuid))

src/Sql/Sql/ServerActiveDirectoryAdministrator/Services/AzureSqlServerActiveDirectoryAdministratorAdapter.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public MicrosoftGraphClient MicrosoftGraphClient
5555
{
5656
if (_microsoftGraphClient == null)
5757
{
58-
_microsoftGraphClient = AzureSession.Instance.ClientFactory.CreateArmClient<MicrosoftGraphClient>(Context, AzureEnvironment.Endpoint.Graph);
58+
_microsoftGraphClient = AzureSession.Instance.ClientFactory.CreateArmClient<MicrosoftGraphClient>(Context, AzureEnvironment.ExtendedEndpoint.MicrosoftGraphUrl);
5959
_microsoftGraphClient.TenantID = Context.Tenant.Id;
6060
}
6161
return _microsoftGraphClient;
@@ -316,7 +316,7 @@ protected Guid GetTenantId()
316316
{
317317
var tenantIdStr = Context.Tenant.Id.ToString();
318318
string adTenant = Context.Environment.GetEndpoint(AzureEnvironment.Endpoint.AdTenant);
319-
string graph = Context.Environment.GetEndpoint(AzureEnvironment.Endpoint.Graph);
319+
string graph = Context.Environment.GetEndpoint(AzureEnvironment.ExtendedEndpoint.MicrosoftGraphUrl);
320320
var tenantIdGuid = Guid.Empty;
321321

322322
if (string.IsNullOrWhiteSpace(tenantIdStr) || !Guid.TryParse(tenantIdStr, out tenantIdGuid))

0 commit comments

Comments
 (0)