concept dotnet in category .net

appears as: dotnet, dotnet
Microservices in .NET Core, Second Edition

This is an excerpt from Manning's book Microservices in .NET Core, Second Edition.

Second you need to have a version of the .NET Core command-line tool. If you did not get it bundled with the IDE, follow the instructions for installing .NET Core at http://dot.net. This gives you a command-line tool called dotnet that you’ll use to perform a number of different tasks involved with microservices, including restoring NuGet packages, building, creating NuGet packages, and running microservices. Throughout the book I will use the dotnet command line for these tasks, but if you prefer you can also do most of them in your IDE.

Now that all the code for the Shopping Cart microservice is in place, you can run it the same way you ran the example in chapter 1: from within Visual Studio, or from the command line with dotnet. You can test out all the endpoints with RestClient or a similar tool. When you first try to fetch a shopping cart with an HTTP GET to /shoppingcart/123, the cart will be empty. Try adding some items to it with an HTTP POST to /shoppingcart/123/items and then fetching it again; the response should contain the added items. You can also look at the event feed at /events, and you should see events for each added item.