diff --git a/sdk/eventhub/event-hubs/samples/usingAadAuth.ts b/sdk/eventhub/event-hubs/samples/usingAadAuth.ts index 3c05373b7e25..8fc30deba9f6 100644 --- a/sdk/eventhub/event-hubs/samples/usingAadAuth.ts +++ b/sdk/eventhub/event-hubs/samples/usingAadAuth.ts @@ -9,13 +9,15 @@ Please ensure that your Azure Event Hubs resource is in US East, US East 2, or West Europe region. AAD Role Based Access Control is not supported in other regions yet. - Register a new application in AAD and assign the "owner" role to it + Register a new application in AAD and assign the "Azure Event Hubs Data Owner (Preview)" role to it - See https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app to register a new application in the Azure Active Directory. - Note down the CLIENT_ID and TENANT_ID from the above step. - In the "Certificates & Secrets" tab, create a secret and note that down. - In the Azure portal, go to your Even Hubs resource and click on the Access control (IAM) - tab. Here, assign "owner" role to the registered application. + tab. Here, assign the "Azure Event Hubs Data Owner (Preview)" role to the registered application. + - For more information on Event Hubs RBAC setup, learn more at + https://docs.microsoft.com/en-us/azure/event-hubs/event-hubs-role-based-access-control) Note: If you are using version 2.1.0 or lower of @azure/event-hubs library, then please use the samples at https://github.com/Azure/azure-sdk-for-js/tree/%40azure/event-hubs_2.1.0/sdk/eventhub/event-hubs/samples instead. @@ -39,6 +41,6 @@ async function main(): Promise { await client.close(); } -main().catch(err => { +main().catch((err) => { console.log("error: ", err); }); diff --git a/sdk/servicebus/service-bus/samples/javascript/gettingStarted/loginWithAzureAccount.js b/sdk/servicebus/service-bus/samples/javascript/gettingStarted/loginWithAzureAccount.js index 2c45fb2b2d64..ea389ce9c951 100644 --- a/sdk/servicebus/service-bus/samples/javascript/gettingStarted/loginWithAzureAccount.js +++ b/sdk/servicebus/service-bus/samples/javascript/gettingStarted/loginWithAzureAccount.js @@ -10,7 +10,7 @@ region. AAD Role Based Access Control is not supported in other regions yet. In the Azure portal, go to your Service Bus resource and click on the Access control (IAM) tab. - Here, assign "owner" role to your account. + Here, assign "Azure Service Bus Data Owner (Preview)" role to your account. */ const { ServiceBusClient } = require("@azure/service-bus"); diff --git a/sdk/servicebus/service-bus/samples/javascript/gettingStarted/servicePrincipalLogin.js b/sdk/servicebus/service-bus/samples/javascript/gettingStarted/servicePrincipalLogin.js index 0b806af081ca..b3cf3851e9aa 100644 --- a/sdk/servicebus/service-bus/samples/javascript/gettingStarted/servicePrincipalLogin.js +++ b/sdk/servicebus/service-bus/samples/javascript/gettingStarted/servicePrincipalLogin.js @@ -9,13 +9,13 @@ Please ensure that your Azure Service Bus resource is in US East, US East 2, or West Europe region. AAD Role Based Access Control is not supported in other regions yet. - Register a new application in AAD and assign the "owner" role to it + Register a new application in AAD and assign the "Azure Service Bus Data Owner (Preview)" role to it - See https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app to register a new application in the Azure Active Directory. - Note down the CLIENT_ID and TENANT_ID from the above step. - In the "Certificates & Secrets" tab, create a secret and note that down. - In the Azure portal, go to your Service Bus resource and click on the Access control (IAM) - tab. Here, assign "owner" role to the registered application. + tab. Here, assign "Azure Service Bus Data Owner (Preview)" role to the registered application. */ const { ServiceBusClient } = require("@azure/service-bus"); diff --git a/sdk/servicebus/service-bus/samples/typescript/gettingStarted/loginWithAzureAccount.ts b/sdk/servicebus/service-bus/samples/typescript/gettingStarted/loginWithAzureAccount.ts index 761609b0e044..3ec4770c80e9 100644 --- a/sdk/servicebus/service-bus/samples/typescript/gettingStarted/loginWithAzureAccount.ts +++ b/sdk/servicebus/service-bus/samples/typescript/gettingStarted/loginWithAzureAccount.ts @@ -10,7 +10,7 @@ region. AAD Role Based Access Control is not supported in other regions yet. In the Azure portal, go to your Service Bus resource and click on the Access control (IAM) tab. - Here, assign "owner" role to your account. + Here, assign "Azure Service Bus Data Owner (Preview)" role to your account. */ import { ServiceBusClient } from "@azure/service-bus"; diff --git a/sdk/servicebus/service-bus/samples/typescript/gettingStarted/servicePrincipalLogin.ts b/sdk/servicebus/service-bus/samples/typescript/gettingStarted/servicePrincipalLogin.ts index 670c36b276bb..f6c670197c03 100644 --- a/sdk/servicebus/service-bus/samples/typescript/gettingStarted/servicePrincipalLogin.ts +++ b/sdk/servicebus/service-bus/samples/typescript/gettingStarted/servicePrincipalLogin.ts @@ -9,13 +9,13 @@ Please ensure that your Azure Service Bus resource is in US East, US East 2, or West Europe region. AAD Role Based Access Control is not supported in other regions yet. - Register a new application in AAD and assign the "owner" role to it + Register a new application in AAD and assign the "Azure Service Bus Data Owner (Preview)" role to it - See https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app to register a new application in the Azure Active Directory. - Note down the CLIENT_ID and TENANT_ID from the above step. - In the "Certificates & Secrets" tab, create a secret and note that down. - In the Azure portal, go to your Service Bus resource and click on the Access control (IAM) - tab. Here, assign "owner" role to the registered application. + tab. Here, assign "Azure Service Bus Data Owner (Preview)" role to the registered application. */ import { ServiceBusClient } from "@azure/service-bus"; diff --git a/sdk/servicebus/service-bus/test/README.md b/sdk/servicebus/service-bus/test/README.md index 3cb02df9ec96..24b735b38c20 100644 --- a/sdk/servicebus/service-bus/test/README.md +++ b/sdk/servicebus/service-bus/test/README.md @@ -105,11 +105,11 @@ Go through the following setup in order to delete and create the required servic **Assign owner role to the registered application** -- In the azure-portal, go to your servicebus-namespace and assign **owner** role to the registered application. -- This can be done from `Access control (IAM)` tab(in the left-side-navbar of your servicebus-namespace in the azure-portal)
-_Doing this would allow the registered application manage the namespace, i.e., entity creation, deletion, etc.,_
-_**Note:** AAD RBAC is enabled only on the new namespaces in this region for the preview. Please ensure that your servicebus-namespace is present in one of these regions: **US East, US East 2, or West Europe**. If not, create the namespace in one of those regions._ - +- In the azure-portal, go to your servicebus-namespace and assign **Azure Service Bus Data Owner (Preview)** role to the registered application. +- This can be done from `Role assignment` section of `Access control (IAM)` tab (in the left-side-navbar of your servicebus-namespace in the azure-portal)
+ _Doing this would allow the registered application manage the namespace, i.e., entity creation, deletion, etc.,_
+ _**Note:** AAD RBAC is enabled only on the new namespaces in this region for the preview. Please ensure that your servicebus-namespace is present in one of these regions: **US East, US East 2, or West Europe**. If not, create the namespace in one of those regions._ +- For more information on Service Bus RBAC setup - [Learn more](https://docs.microsoft.com/en-us/azure/service-bus-messaging/service-bus-role-based-access-control) **Update your environment variables**