AzureMonitor: strongly-typed AzureCredentials and correct resolution of auth type and cloud (#36284)

This commit is contained in:
Sergey Kostrukov authored and GitHub committed 2021-07-05 12:20:12 +02:00
1 parent 719e78f333
commit 89ba607382
15 files changed
+748 -403

No files matched your search

+1 -2
View File
@@ -92,8 +92,7 @@ func getTokenProvider(ctx context.Context, cfg *setting.Cfg, ds *models.DataSour
if tokenAuth == nil {
return nil, fmt.Errorf("'tokenAuth' not configured for authentication type '%s'", authType)
}
provider := newAzureAccessTokenProvider(ctx, cfg, tokenAuth)
return provider, nil
return newAzureAccessTokenProvider(ctx, cfg, tokenAuth)
case "gce":
if jwtTokenAuth == nil {