Skip to content

Commit 07adbca

Browse files
committed
make connection string option default
1 parent 2537ff4 commit 07adbca

9 files changed

+114
-101
lines changed

articles/service-bus-messaging/includes/service-bus-create-namespace-portal.md

-12
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,3 @@ To create a namespace:
4646

4747
:::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." :::
4848

49-
## Get the connection string
50-
Creating a new namespace automatically generates an initial Shared Access Signature (SAS) policy with primary and secondary keys, and primary and secondary connection strings that each grant full control over all aspects of the namespace. See [Service Bus authentication and authorization](../service-bus-authentication-and-authorization.md) for information about how to create rules with more constrained rights for regular senders and receivers.
51-
52-
A client can use the connection string to connect to the Service Bus namespace. To copy the primary connection string for your namespace, follow these steps:
53-
54-
1. On the **Service Bus Namespace** page, select **Shared access policies** on the left menu.
55-
3. On the **Shared access policies** page, select **RootManageSharedAccessKey**.
56-
4. In the **Policy: RootManageSharedAccessKey** window, select the copy button next to **Primary Connection String**, to copy the connection string to your clipboard for later use. Paste this value into Notepad or some other temporary location.
57-
58-
:::image type="content" source="./media/service-bus-create-namespace-portal/connection-string.png" lightbox="./media/service-bus-create-namespace-portal/connection-string.png" alt-text="Screenshot shows an S A S policy called RootManageSharedAccessKey, which includes keys and connection strings.":::
59-
60-
You can use this page to copy primary key, secondary key, primary connection string, and secondary connection string.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
---
2+
title: "include file"
3+
description: "include file"
4+
services: storage
5+
author: alexwolfmsft
6+
ms.service: storage
7+
ms.topic: include
8+
ms.date: 09/09/2022
9+
ms.author: alexwolf
10+
ms.custom: include file
11+
---
12+
13+
14+
15+
## [Connection String](#tab/connection-string)
16+
17+
## Get the connection string
18+
Creating a new namespace automatically generates an initial Shared Access Signature (SAS) policy with primary and secondary keys, and primary and secondary connection strings that each grant full control over all aspects of the namespace. See [Service Bus authentication and authorization](../service-bus-authentication-and-authorization.md) for information about how to create rules with more constrained rights for regular senders and receivers.
19+
20+
A client can use the connection string to connect to the Service Bus namespace. To copy the primary connection string for your namespace, follow these steps:
21+
22+
1. On the **Service Bus Namespace** page, select **Shared access policies** on the left menu.
23+
3. On the **Shared access policies** page, select **RootManageSharedAccessKey**.
24+
4. In the **Policy: RootManageSharedAccessKey** window, select the copy button next to **Primary Connection String**, to copy the connection string to your clipboard for later use. Paste this value into Notepad or some other temporary location.
25+
26+
:::image type="content" source="./media/service-bus-create-namespace-portal/connection-string.png" lightbox="./media/service-bus-create-namespace-portal/connection-string.png" alt-text="Screenshot shows an S A S policy called RootManageSharedAccessKey, which includes keys and connection strings.":::
27+
28+
You can use this page to copy primary key, secondary key, primary connection string, and secondary connection string.
29+
30+
31+
## [Passwordless (Recommended)](#tab/passwordless)
32+
33+
## Authenticate the app to Azure
34+
35+
[!INCLUDE [passwordless-overview](../../../includes/passwordless/passwordless-overview.md)]
36+
37+
[!INCLUDE [passwordless-default-azure-credential-overview](../../../includes/passwordless/dotnet-default-azure-credential-overview.md)]
38+
39+
### Assign roles to your Azure AD user
40+
41+
[!INCLUDE [service-bus-assign-roles](service-bus-assign-roles.md)]
42+
43+
### Sign in and add the Azure Identity package
44+
45+
You can authorize access to the service bus namespace using the following steps:
46+
47+
[!INCLUDE [default-azure-credential-sign-in](../../../includes/passwordless/default-azure-credential-sign-in.md)]
48+
49+
[!INCLUDE [visual-studio-add-identity](../../../includes/passwordless/visual-studio-add-identity.md)]
50+
51+
52+
---

articles/service-bus-messaging/service-bus-dotnet-get-started-with-queues.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ If you're new to the service, see [Service Bus overview](service-bus-messaging-o
2727
- **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).
2828
- **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.
2929

30-
[!INCLUDE [service-bus-create-namespace-portal-passwordless](../../includes/passwordless/service-bus/service-bus-create-namespace-portal-passwordless.md)]
30+
[!INCLUDE [service-bus-create-namespace-portal-passwordless](./includes/passwordless/service-bus/service-bus-create-namespace-portal-passwordless.md)]
3131

3232
[!INCLUDE [service-bus-create-queue-portal](./includes/service-bus-create-queue-portal.md)]
3333

@@ -63,7 +63,7 @@ This section shows you how to create a .NET console application to send messages
6363
Install-Package Azure.Messaging.ServiceBus
6464
```
6565
66-
[!INCLUDE [service-bus-passwordless-template-tabbed](../../includes/passwordless/service-bus/service-bus-passwordless-template-tabbed.md)]
66+
[!INCLUDE [service-bus-passwordless-template-tabbed](./includes/passwordless/service-bus/service-bus-passwordless-template-tabbed.md)]
6767
6868
## Add code to send messages to the queue
6969

0 commit comments

Comments
 (0)