You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/service-bus-messaging/service-bus-dotnet-get-started-with-queues.md
+4-6Lines changed: 4 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,6 +19,8 @@ In this quickstart, you'll do the following steps:
19
19
20
20
> [!NOTE]
21
21
> - This quick start provides step-by-step instructions to implement a simple scenario of sending a batch of messages to a Service Bus queue and then receiving them. For an overview of the .NET client library, see [Azure Service Bus client library for .NET](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/servicebus/Azure.Messaging.ServiceBus/README.md). For more samples, see [Service Bus .NET samples on GitHub](https://github.com/Azure/azure-sdk-for-net/tree/master/sdk/servicebus/Azure.Messaging.ServiceBus/samples).
22
+
> - This quick start shows you two ways of connecting to Azure Service Bus: **connection string** and **passwordless**. The first option shows you how to use a connection string to connect to a Service Bus namespace. The second option shows you how to use your security principal in Azure Active Directory and the role-based access control (RBAC) to connect to a Service Bus namespace. You don't need to worry about having hard-coded connection string in your code or in a configuration file or in secure storage like Azure Key Vault. If you are new to Azure, you may find the connection string option easier to follow. We recommend using the passwordless option in real-world applications and production environments. For more information, see [Authentication and authorization](service-bus-authentication-and-authorization.md).
23
+
22
24
23
25
## Prerequisites
24
26
@@ -27,14 +29,8 @@ If you're new to the service, see [Service Bus overview](service-bus-messaging-o
27
29
-**Azure subscription**. To use Azure services, including Azure Service Bus, you need a subscription. If you don't have an existing Azure account, you can sign up for a [free trial](https://azure.microsoft.com/free/dotnet).
28
30
-**Visual Studio 2022**. The sample application makes use of new features that were introduced in C# 10. You can still use the Service Bus client library with previous C# language versions, but the syntax may vary. To use the latest syntax, we recommend that you install .NET 6.0 or higher and set the language version to `latest`. If you're using Visual Studio, versions before Visual Studio 2022 aren't compatible with the tools needed to build C# 10 projects.
@@ -260,6 +256,8 @@ This section shows you how to create a .NET console application to send messages
260
256
A batch of 3 messages has been published to the queue
261
257
```
262
258
259
+
> [!IMPORTANT]
260
+
> In most cases, it will take a minute or two for the role assignment to propagate in Azure. In rare cases, it may take up to **eight minutes**. If you receive authentication errors when you first run your code, wait a few moments and try again.
263
261
8. In the Azure portal, follow these steps:
264
262
1. Navigate to your Service Bus namespace.
265
263
1. On the **Overview** page, select the queue in the bottom-middle pane.
Copy file name to clipboardExpand all lines: articles/service-bus-messaging/service-bus-dotnet-how-to-use-topics-subscriptions.md
+4-6Lines changed: 4 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,6 +29,7 @@ In this quickstart, you'll do the following steps:
29
29
30
30
> [!NOTE]
31
31
> This quick start provides step-by-step instructions to implement a simple scenario of sending a batch of messages to a Service Bus topic and receiving those messages from a subscription of the topic. For more samples on other and advanced scenarios, see [Service Bus .NET samples on GitHub](https://github.com/Azure/azure-sdk-for-net/tree/master/sdk/servicebus/Azure.Messaging.ServiceBus/samples).
32
+
> - This quick start shows you two ways of connecting to Azure Service Bus: **connection string** and **passwordless**. The first option shows you how to use a connection string to connect to a Service Bus namespace. The second option shows you how to use your security principal in Azure Active Directory and the role-based access control (RBAC) to connect to a Service Bus namespace. You don't need to worry about having hard-coded connection string in your code or in a configuration file or in secure storage like Azure Key Vault. If you are new to Azure, you may find the connection string option easier to follow. We recommend using the passwordless option in real-world applications and production environments. For more information, see [Authentication and authorization](service-bus-authentication-and-authorization.md).
32
33
33
34
## Prerequisites
34
35
@@ -37,14 +38,8 @@ If you're new to the service, see [Service Bus overview](service-bus-messaging-o
37
38
-**Azure subscription**. To use Azure services, including Azure Service Bus, you need a subscription. If you don't have an existing Azure account, you can sign up for a [free trial](https://azure.microsoft.com/free/dotnet/).
38
39
-**Visual Studio 2022**. The sample application makes use of new features that were introduced in C# 10. You can still use the Service Bus client library with previous C# language versions, but the syntax may vary. To use the latest syntax, we recommend that you install .NET 6.0 or higher and set the language version to `latest`. If you're using Visual Studio, versions before Visual Studio 2022 aren't compatible with the tools needed to build C# 10 projects.
@@ -246,6 +241,9 @@ This section shows you how to create a .NET console application to send messages
246
241
```bash
247
242
A batch of 3 messages has been published to the topic
248
243
```
244
+
245
+
> [!IMPORTANT]
246
+
> In most cases, it will take a minute or two for the role assignment to propagate in Azure. In rare cases, it may take up to **eight minutes**. If you receive authentication errors when you first run your code, wait a few moments and try again.
249
247
1. In the Azure portal, follow these steps:
250
248
1. Navigate to your Service Bus namespace.
251
249
1. On the **Overview** page, in the bottom-middle pane, switch to the **Topics** tab, and select the Service Bus topic. In the following example, it's `mytopic`.
Copy file name to clipboardExpand all lines: includes/passwordless/service-bus/service-bus-assign-roles.md
+2-15Lines changed: 2 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,25 +23,12 @@ For Azure Service Bus, the management of namespaces and all related resources th
23
23
24
24
If you want to create a custom role, see [Rights required for Service Bus operations](../../../articles/service-bus-messaging/service-bus-sas.md#rights-required-for-service-bus-operations).
25
25
26
-
### Create a user in Azure Active Directory
27
-
28
-
If you already have an Azure Active Directory (Azure AD) user account, skip this step. If not (for example, if you logged in using a Microsoft account like: `[email protected]`), create a user in Azure AD.
29
-
30
-
1. Sign-in to [Azure portal](https://portal.azure.com) in a new tab or new web browser window.
31
-
1. In the search bar at the top, type **Azure Active Directory**, and select **Azure Active Directory** from the results.
32
-
1. On the Azure Active Directory page, select **Users** under **Manage** on the left navigational menu.
33
-
1. On the **Users** page, select **+ New user** on the command bar, and then select **Create new user**.
34
-
1. On the **New user** page, follow these steps:
35
-
1. For **User name**, enter a name for the user. For example: **john.doe**.
36
-
1. For **Name**, specify the full name. For example: **John Doe**.
37
-
1. Select **Create** to create the user in Azure AD.
38
-
39
26
### Add Azure AD user to Azure Service Bus Owner role
40
27
41
-
Add your Azure AD user name or the one you created in the previous step to the **Azure Service Bus Data Owner** role at the Service Bus namespace level. It will allow an app running in the context of this user account to send messages to a queue or a topic, and receive messages from a queue or a topic's subscription.
28
+
Add your Azure AD user name to the **Azure Service Bus Data Owner** role at the Service Bus namespace level. It will allow an app running in the context of your user account to send messages to a queue or a topic, and receive messages from a queue or a topic's subscription.
42
29
43
30
> [!IMPORTANT]
44
-
> In most cases, it will take a minute or two for the role assignment to propagate in Azure. In rare cases, it may take up to eight minutes. If you receive authentication errors when you first run your code, wait a few moments and try again.
31
+
> In most cases, it will take a minute or two for the role assignment to propagate in Azure. In rare cases, it may take up to **eight minutes**. If you receive authentication errors when you first run your code, wait a few moments and try again.
45
32
46
33
1. If you don't have the Service Bus Namespace page open in the Azure portal, locate your Service Bus namespace using the main search bar or left navigation.
47
34
2. On the overview page, select **Access control (IAM)** from the left-hand menu.
Copy file name to clipboardExpand all lines: includes/passwordless/service-bus/service-bus-create-namespace-portal-passwordless.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,7 @@ To create a namespace:
32
32
1. For **Pricing tier**, select the pricing tier (Basic, Standard, or Premium) for the namespace. For this quickstart, select **Standard**.
33
33
34
34
> [!IMPORTANT]
35
-
> If you want to use [Topics and subscriptions](../../../articles/service-bus-messaging/service-bus-queues-topics-subscriptions.md#topics-and-subscriptions), choose either Standard or Premium. Topics/subscriptions aren't supported in the Basic pricing tier.
35
+
> If you want to use [Topics and subscriptions](../../../articles/service-bus-messaging/service-bus-queues-topics-subscriptions.md#topics-and-subscriptions), choose either Standard or [Premium](../../../articles/service-bus-messaging/service-bus-premium-messaging.md). Topics/subscriptions aren't supported in the Basic pricing tier.
36
36
37
37
If you selected the **Premium** pricing tier, specify the number of **messaging units**. The premium tier provides resource isolation at the CPU and memory level so that each workload runs in isolation. This resource container is called a messaging unit. A premium namespace has at least one messaging unit. You can select 1, 2, 4, 8 or 16 messaging units for each Service Bus Premium namespace. For more information, see [Service Bus Premium Messaging](../../../articles/service-bus-messaging/service-bus-premium-messaging.md).
38
38
@@ -45,4 +45,4 @@ To create a namespace:
45
45
:::image type="content" source="./media/service-bus-create-namespace-portal/deployment-alert.png" alt-text="Image showing the deployment succeeded page with the Go to resource link.":::
46
46
5. You see the home page for your service bus namespace.
47
47
48
-
:::image type="content" source="./media/service-bus-create-namespace-portal/service-bus-namespace-home-page.png" alt-text="Image showing the home page of the Service Bus namespace created." :::
48
+
:::image type="content" source="./media/service-bus-create-namespace-portal/service-bus-namespace-home-page.png" lightbox="./media/service-bus-create-namespace-portal/service-bus-namespace-home-page.png" alt-text="Image showing the home page of the Service Bus namespace created." :::
0 commit comments