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
@@ -319,25 +319,25 @@ Next, you'll add the Azure SDK for .NET to this sample project and use the libra
319
319
private readonly CosmosClient _client;
320
320
```
321
321
322
-
1. Create a new empty constructor for the `CosmosClient` class.
322
+
1. Create a new empty constructor for the `CosmosService` class.
323
323
324
324
```csharp
325
-
public CosmosClient()
325
+
public CosmosService()
326
326
{ }
327
327
```
328
328
329
329
1. Within the constructor, create a new instance of the `CosmosClient` class passing in a string parameter with the **PRIMARY CONNECTION STRING** value you previously recorded in the lab. Store this new instance in the `_client` member.
330
330
331
331
```csharp
332
-
public CosmosClient()
332
+
public CosmosService()
333
333
{
334
334
_client = new CosmosClient(
335
335
connectionString: "<primary-connection-string>"
336
336
);
337
337
}
338
338
```
339
339
340
-
1. Back within the **CosmosClient** class, create a new `private` property of type`Container` named `container`. Set the **get accessor** to return the `cosmicworks` database and `products` container.
340
+
1. Back within the **CosmosService** class, create a new `private` property of type`Container` named `container`. Set the **get accessor** to return the `cosmicworks` database and `products` container.
341
341
342
342
```csharp
343
343
private Container container
@@ -485,12 +485,9 @@ Finally, you'll run the application with **hot reloads** enabled. Running the ap
485
485
1. Back in the terminal, run the application.
486
486
487
487
```bash
488
-
dotnet watch
488
+
dotnet run
489
489
```
490
490
491
-
> [!NOTE]
492
-
> `dotnet watch` is enabled here so you can quickly change the code if you find a mistake.
493
-
494
491
1. The output of the run command should include a list of ports and URLs where the application is running. Open a new browser and navigate to the running web application. Observe all three pages of the running application. Each page should now include live data from Azure Cosmos DB.
0 commit comments