Skip to content

Commit d4447bd

Browse files
authored
Merge pull request #102872 from spelluru/ehubdotnet0130
updated
2 parents fc671b4 + 563b466 commit d4447bd

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

articles/event-hubs/get-started-dotnet-standard-send-v2.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ This section shows you how to create a .NET Core console application to send eve
5555
1. Run the following command to install the **Azure.Messaging.EventHubs** NuGet package:
5656

5757
```cmd
58-
Install-Package Azure.Messaging.EventHubs -Version 5.0.0
58+
Install-Package Azure.Messaging.EventHubs
5959
```
6060
6161
@@ -73,8 +73,8 @@ This section shows you how to create a .NET Core console application to send eve
7373
2. Add constants to the `Program` class for the Event Hubs connection string and the event hub name. Replace placeholders in brackets with the proper values that you got when creating the event hub. Make sure that the `{Event Hubs namespace connection string}` is the namespace-level connection string, and not the event hub string.
7474
7575
```csharp
76-
private static readonly string connectionString = "<EVENT HUBS NAMESPACE - CONNECTION STRING>";
77-
private static readonly string eventHubName = "<EVENT HUB NAME>";
76+
private const string connectionString = "<EVENT HUBS NAMESPACE - CONNECTION STRING>";
77+
private const string eventHubName = "<EVENT HUB NAME>";
7878
```
7979
8080
3. Replace the `Main` method with the following `async Main` method. See the code comments for details.
@@ -134,12 +134,12 @@ In this quickstart, you use Azure Storage as the checkpoint store. Follow these
134134
1. Run the following command to install the **Azure.Messaging.EventHubs** NuGet package:
135135
136136
```cmd
137-
Install-Package Azure.Messaging.EventHubs -Version 5.0.0
137+
Install-Package Azure.Messaging.EventHubs
138138
```
139139
1. Run the following command to install the **Azure.Messaging.EventHubs.Processor** NuGet package:
140140
141141
```cmd
142-
Install-Package Azure.Messaging.EventHubs.Processor -Version 5.0.0
142+
Install-Package Azure.Messaging.EventHubs.Processor
143143
```
144144
145145
### Update the Main method
@@ -157,10 +157,10 @@ In this quickstart, you use Azure Storage as the checkpoint store. Follow these
157157
1. Add constants to the `Program` class for the Event Hubs connection string and the event hub name. Replace placeholders in brackets with the proper values that you got when creating the event hub. Replace placeholders in brackets with the proper values that you got when creating the event hub and the storage account (access keys - primary connection string). Make sure that the `{Event Hubs namespace connection string}` is the namespace-level connection string, and not the event hub string.
158158
159159
```csharp
160-
private static readonly string ehubNamespaceConnectionString = "<EVENT HUBS NAMESPACE - CONNECTION STRING>";
161-
private static readonly string eventHubName = "<EVENT HUB NAME>";
162-
private static readonly string blobStorageConnectionString = "<AZURE STORAGE CONNECTION STRING>";
163-
private static readonly string blobContainerName = "<BLOB CONTAINER NAME>";
160+
private const string ehubNamespaceConnectionString = "<EVENT HUBS NAMESPACE - CONNECTION STRING>";
161+
private const string eventHubName = "<EVENT HUB NAME>";
162+
private const string blobStorageConnectionString = "<AZURE STORAGE CONNECTION STRING>";
163+
private const string blobContainerName = "<BLOB CONTAINER NAME>";
164164
```
165165
3. Replace the `Main` method with the following `async Main` method. See the code comments for details.
166166

0 commit comments

Comments
 (0)