Tutorials Microservices with .NET

Project Setup for Microservices in ASP.NET Core Web API — Complete Guide

Project Setup for Microservices in ASP.NET Core Web API — Complete Guide: free step-by-step lesson with examples, common mistakes, and interview tips — part of Microservices with .NET on Toolliyo Academy.

On this page

Microservices with .NET · Lesson 7 of 131

Project Setup for Microservices in ASP.NET Core Web API

BeginnerIntermediateAdvancedProfessional

Beginner · 1 — Foundations · ~6 min · Module 1: Foundations and Fundamentals

What is this?

Project setup is how you organize ShopNest on disk — one folder per service, shared solution or separate repos, docker-compose later, and consistent naming (ShopNest.Order.Api).

Why should you care?

Messy folders on day one become messy deploys on day hundred. A clear layout helps you clone the Order pattern for Payment in ten minutes.

See it live — copy this example

Create a Web API project (dotnet new webapi), paste the code, then run dotnet run.

ShopNest/
  src/
    Order.Api/
    Order.Domain/
    Product.Api/
    Product.Domain/
  ShopNest.sln
  docker-compose.yml   ← added in lesson 73

Run Example »

This lesson uses terminal or setup steps. Run commands on your computer — the live editor appears on coding lessons.

What happened?

  • Each service is its own .NET project with its own Program.cs.
  • Solution file ties them for local dev.
  • Gateway and docker-compose appear in later modules.

Try it yourself

  1. mkdir ShopNest && cd ShopNest
  2. dotnet new sln -n ShopNest
  3. dotnet new webapi -n Order.Api -o src/Order.Api
  4. Change a string or route in the example and save — watch Swagger or the RabbitMQ Management UI update.
  5. Break the code on purpose (remove a semicolon), read the error message, then fix it.

Remember

One deployable service = one (or few) .NET projects. Use a solution to build all services locally. Name projects after business capability: Order.Api, not ShopNestWebApi2.

Real-world: Team ownership

Flipkart Order team owns src/Order.* pipelines. Their GitHub Actions deploy only Order.Api when Order files change.

Outcome: Independent deploy starts with independent folders and CI paths.

Microservices with .NET
Course syllabus
Module 1: Foundations and Fundamentals Introduction to Microservices Architecture — Complete Guide Monolith vs Microservices — Complete Guide Microservices Design Principles — Complete Guide ASP.NET Core Web API Fundamentals — Complete Guide Clean Architecture in ASP.NET Core Web API — Complete Guide Domain-Driven Design in ASP.NET Core Web API — Complete Guide Project Setup for Microservices in ASP.NET Core Web API — Complete Guide Data Management Strategies in Microservices — Complete Guide Database Per Service Pattern — Complete Guide Shared Database Anti-Pattern — Complete Guide
Module 2: Building User Microservice Building User Microservice — Complete Guide User Microservice with ASP.NET Core Web API — Complete Guide Implementing User Microservice Domain Layer — Complete Guide Implementing User Microservice Infrastructure Layer — Complete Guide Implementing User Microservice Application Layer — Complete Guide Implementing User Microservice API Layer — Complete Guide
Module 3: ShopNest Services and Integration Product Microservice — Complete Guide Order Microservice — Complete Guide Notification Microservice — Complete Guide Payment Microservice — Complete Guide Inventory Microservice — Complete Guide API Contracts — Complete Guide Shared Libraries — Complete Guide Inter-Service Communication in Microservices — Complete Guide DTO and Mapping Strategies — Complete Guide
Module 4: RabbitMQ and Messaging RabbitMQ in Microservices — Complete Guide RabbitMQ for Asynchronous Messaging in Microservices — Complete Guide RabbitMQ Installation and Setup on Windows — Complete Guide RabbitMQ Management UI End-to-End Test — Complete Guide RabbitMQ Integration Steps — Complete Guide Integrating RabbitMQ in ASP.NET Core Web API — Complete Guide End-to-end Order Placed Communication using RabbitMQ — Complete Guide Publish-Subscribe Pattern — Complete Guide Event-Driven Architecture — Complete Guide Dead Letter Queues — Complete Guide
Module 5: Saga and Distributed Transactions Saga Pattern in Microservices — Complete Guide Choreography Saga — Complete Guide Orchestration Saga — Complete Guide Shared Messaging Infrastructure for Saga — Complete Guide Saga in Order Service — Complete Guide Orchestrator Service for Saga — Complete Guide Saga in Product Service — Complete Guide Saga in Notification Service — Complete Guide Payment Service Saga — Complete Guide Distributed Transactions and Eventual Consistency — Complete Guide
Module 6: API Gateway API Gateway in Microservices — Complete Guide API Gateway in ASP.NET Core Web API — Complete Guide Ocelot API Gateway — Complete Guide YARP API Gateway — Complete Guide JWT Authentication in API Gateway — Complete Guide Response Aggregation in API Gateway — Complete Guide Response Compression in API Gateway — Complete Guide Response Caching in API Gateway — Complete Guide Rate Limiting and Throttling in API Gateway — Complete Guide Logging with Ocelot API Gateway — Complete Guide
Module 7: gRPC, CQRS, and GraphQL gRPC Fundamentals — Complete Guide gRPC in ASP.NET Core Web API — Complete Guide CQRS in ASP.NET Core Web API — Complete Guide Implementing CQRS in ASP.NET Core Microservices — Complete Guide GraphQL in ASP.NET Core Web API — Complete Guide Hot Chocolate GraphQL — Complete Guide Circuit Breaker in ASP.NET Core Web API — Complete Guide CORS in ASP.NET Core Web API — Complete Guide OData in ASP.NET Core Web API — Complete Guide Service Discovery — Complete Guide
Module 8: Resiliency and Fault Tolerance Retry Pattern — Complete Guide Polly Integration — Complete Guide Timeout Policies — Complete Guide Fallback Mechanisms — Complete Guide Bulkhead Pattern — Complete Guide Health Checks — Complete Guide Distributed Cache — Complete Guide Rate Limiting in Services — Complete Guide Failover Strategies — Complete Guide Backend for Frontend — Complete Guide
Module 9: DevOps and Cloud-Native Docker Fundamentals — Complete Guide Dockerizing ASP.NET Core Services — Complete Guide Docker Compose — Complete Guide Kubernetes Fundamentals — Complete Guide Kubernetes Deployment — Complete Guide Helm Charts — Complete Guide Azure Kubernetes Service — Complete Guide Secrets Management — Complete Guide ConfigMaps — Complete Guide Blue-Green Deployment — Complete Guide
Module 10: Git and GitHub Introduction to Source Code Management — Complete Guide Installing Git and GitHub in Visual Studio — Complete Guide Creating a Git Repository for ASP.NET Core Web API — Complete Guide Core Git Concepts — Complete Guide Git Branching for ASP.NET Core Development — Complete Guide Git Commit Best Practices — Complete Guide Merging and Resolving Conflicts in Git — Complete Guide Working with GitHub Remote Repositories — Complete Guide How Git and GitHub Work Together — Complete Guide Git Revert vs Git Reset — Complete Guide Git Logs and History — Complete Guide
Module 11: CI/CD Pipelines Introduction to CI/CD Pipelines in .NET — Complete Guide Preparing ASP.NET Core Web API for CI/CD — Complete Guide Building CI Pipeline with GitHub Actions — Complete Guide Managing Secrets and Configuration in CI/CD — Complete Guide Automating Deployment to IIS with GitHub Actions — Complete Guide IIS and Azure Deployment — Complete Guide
Module 12: Observability and Testing OpenTelemetry — Complete Guide Distributed Tracing — Complete Guide Serilog — Complete Guide Grafana — Complete Guide Prometheus — Complete Guide Unit Testing — Complete Guide Integration Testing — Complete Guide Contract Testing — Complete Guide Load Testing — Complete Guide Production Monitoring — Complete Guide
Module 13: Advanced Topics Event Sourcing — Complete Guide Outbox Pattern — Complete Guide Domain Events — Complete Guide API Versioning — Complete Guide Retry Using Polly — Complete Guide Identity Server — Complete Guide OAuth2 and OpenID Connect — Complete Guide Strangler Fig Pattern — Complete Guide Multi-Tenant Microservices — Complete Guide
Module 14: Real-World Enterprise Projects E-Commerce Microservices — Complete Guide Banking Microservices — Complete Guide Food Delivery Platform — Complete Guide Ride Booking Platform — Complete Guide ERP Microservices — Complete Guide SaaS Multi-Tenant Platform — Complete Guide Payment Gateway System — Complete Guide Notification Platform — Complete Guide Distributed Analytics System — Complete Guide Enterprise Cloud-Native Platform — Capstone
Toolliyo Assistant
Ask about tutorials, ebooks, training, pricing, mentor services, and support. I use public site content only—not admin or internal tools.

care@toolliyo.com

Need callback? Share your details