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
@@ -115,7 +115,7 @@ Next, update your code to use passwordless connections.
115
115
usingAzure.Identity;
116
116
```
117
117
118
-
1. Identify the locations in your code that create a `ServiceBusClient` object to connect to Azure Service Bus. Update your code to match the following example:
118
+
1. Identify the code that creates a `ServiceBusClient` object to connect to Azure Service Bus. Update your code to match the following example:
119
119
120
120
```csharp
121
121
//TODO: Replace the <SERVICE-BUS-NAMESPACE-NAME> placeholder.
@@ -126,77 +126,70 @@ Next, update your code to use passwordless connections.
126
126
127
127
## [Java](#tab/java)
128
128
129
-
1. To use `DefaultAzureCredential` in a Java application, install the `azure-identity` package via one of the following approaches:
130
-
1.[Include the BOM file](/java/api/overview/azure/identity-readme?view=azure-java-stable&preserve-view=true#include-the-bom-file).
131
-
1.[Include a direct dependency](/java/api/overview/azure/identity-readme?view=azure-java-stable&preserve-view=true#include-direct-dependency).
132
-
133
-
1. At the top of your file, add the following code:
- In a JMS application, add at least version 1.0.0 of the `azure-servicebus-jms` package to your application:
138
131
139
-
1.Identify the locations in your code that create a ServiceBus sender or receiver client object to connect to AzureServiceBus. Update your code to match one of the following examples:
132
+
```xml
133
+
<dependency>
134
+
<groupId>com.microsoft.azure</groupId>
135
+
<artifactId>azure-servicebus-jms</artifactId>
136
+
<version>1.0.0</version>
137
+
</dependency>
138
+
```
140
139
141
-
**Receiver client:**
140
+
- In a Java application, install the `azure-identity` package via one of the following approaches:
141
+
1. [Include the BOM file](/java/api/overview/azure/identity-readme?view=azure-java-stable&preserve-view=true#include-the-bom-file).
142
+
1. [Include a direct dependency](/java/api/overview/azure/identity-readme?view=azure-java-stable&preserve-view=true#include-direct-dependency).
1.Identify the locations in your code that currently create a `ServiceBusJmsConnectionFactory` object to connect to AzureServiceBus. Update your code to match the following example:
1. Update the code that connects to Azure Service Bus:
151
+
- In a JMS application, identify the code that creates a `ServiceBusJmsConnectionFactory` object to connect to Azure Service Bus. Update your code to match the following example:
193
152
194
-
//TODO: Replace the "<SERVICE-BUS-NAMESPACE-NAME>" placeholder.
- In a Java application, identify the code that creates a Service Bus sender or receiver client object to connect to Azure Service Bus. Update your code to match one of the following examples:
165
+
166
+
**Receiver client:**
167
+
168
+
```java
169
+
DefaultAzureCredential credential = new DefaultAzureCredentialBuilder()
170
+
.build();
171
+
172
+
ServiceBusReceiverClient receiver = new ServiceBusClientBuilder()
1. Identify the locations in your code that create a `ServiceBusClient` object to connect to Azure Service Bus. Update your code to match the following example:
208
+
1. Identify the code that creates a `ServiceBusClient` object to connect to Azure Service Bus. Update your code to match the following example:
216
209
217
210
```nodejs
218
211
const credential = new DefaultAzureCredential();
@@ -238,7 +231,7 @@ Next, update your code to use passwordless connections.
238
231
from azure.identity import DefaultAzureCredential
239
232
```
240
233
241
-
1. Identify the locations in your code that create a `ServiceBusClient` object to connect to Azure Service Bus. Update your code to match the following example:
234
+
1. Identify the code that creates a `ServiceBusClient` object to connect to Azure Service Bus. Update your code to match the following example:
242
235
243
236
```python
244
237
credential = DefaultAzureCredential()
@@ -391,7 +384,7 @@ If you connected your services using the Service Connector you don't need to com
391
384
392
385
### [Azure CLI](#tab/assign-role-azure-cli)
393
386
394
-
To assign a role at the resource level using the Azure CLI, you first must retrieve the resource ID using the `az servicebus show` command. You can filter the output properties using the --query parameter.
387
+
To assign a role at the resource level using the Azure CLI, you first must retrieve the resource ID using the `az servicebus show` command. You can filter the output properties using the `--query` parameter.
0 commit comments