Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 0cec8af

Browse files
2 parents e844f3a + fb486c0 commit 0cec8af

File tree

1 file changed

+26
-62
lines changed

1 file changed

+26
-62
lines changed

‎README.md

Lines changed: 26 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -2,39 +2,38 @@
22

33
See the overall picture of **implementations on microservices with .net tools** on real-world **e-commerce microservices** project;
44

5-
![microservices_remastered](https://user-images.githubusercontent.com/1147445/110304529-c5b70180-800c-11eb-832b-a2751b5bda76.png)
5+
![microservices](https://github.com/aspnetrun/run-aspnetcore-microservices/assets/1147445/efe5e688-67f2-4ddd-af37-d9d3658aede4)
66

7-
There is a couple of microservices which implemented **e-commerce** modules over **Catalog, Basket, Discount** and **Ordering** microservices with **NoSQL (MongoDB, Redis)** and **Relational databases (PostgreSQL, Sql Server)** with communicating over **RabbitMQ Event Driven Communication** and using **Ocelot API Gateway**.
8-
9-
And here continuation of the main course -> [Microservices Observability with Distributed Logging, Health Monitoring, Resilient and Fault Tolerance with using Polly](https://www.udemy.com/course/microservices-observability-resilience-monitoring-on-net/?referralCode=D162C050483C75452136)
7+
There is a couple of microservices which implemented **e-commerce** modules over **Catalog, Basket, Discount** and **Ordering** microservices with **NoSQL (DocumentDb, Redis)** and **Relational databases (PostgreSQL, Sql Server)** with communicating over **RabbitMQ Event Driven Communication** and using **Yarp API Gateway**.
108

119
### Check Explanation of this Repository on Medium
12-
* [Microservices Architecture on .NET with applying CQRS, Clean Architecture and Event-Driven Communication](https://medium.com/aspnetrun/microservices-architecture-on-net-3b4865eea03f)
13-
* [Microservices Observability, Resilience, Monitoring on .Net](https://medium.com/aspnetrun/microservices-observability-resilience-monitoring-on-net-a5dfbdbb0fbd)
10+
* [.NET 8 Microservices: DDD, CQRS, Vertical/Clean Architecture and Event-Driven Communication](https://medium.com/@mehmetozkaya/net-8-microservices-ddd-cqrs-vertical-clean-architecture-2dd7ebaaf4bd)
1411

1512
## Whats Including In This Repository
1613
We have implemented below **features over the run-aspnetcore-microservices repository**.
1714

1815
#### Catalog microservice which includes;
19-
* ASP.NET Core Web API application
20-
* REST API principles, CRUD operations
21-
* **MongoDB database** connection and containerization
22-
* Repository Pattern Implementation
23-
* Swagger Open API implementation
16+
* ASP.NET Core Minimal APIs and latest features of .NET8 and C# 12
17+
* **Vertical Slice Architecture** implementation with Feature folders and single .cs file includes different classes in one file
18+
* CQRS implementation using MediatR library
19+
* CQRS Validation Pipeline Behaviors with MediatR and FluentValidation
20+
* Use Marten library for .NET Transactional Document DB on PostgreSQL
21+
* Use Carter for Minimal API endpoint definition
22+
* Cross-cutting concerns Logging, Global Exception Handling and Health Checks
2423

2524
#### Basket microservice which includes;
26-
* ASP.NET Web API application
27-
* REST API principles, CRUD operations
28-
* **Redis database** connection and containerization
25+
* ASP.NET 8 Web API application, Following REST API principles, CRUD
26+
* Using **Redis** as a **Distributed Cache** over basketdb
27+
* Implements Proxy, Decorator and Cache-aside patterns
2928
* Consume Discount **Grpc Service** for inter-service sync communication to calculate product final price
3029
* Publish BasketCheckout Queue with using **MassTransit and RabbitMQ**
3130

3231
#### Discount microservice which includes;
3332
* ASP.NET **Grpc Server** application
3433
* Build a Highly Performant **inter-service gRPC Communication** with Basket Microservice
3534
* Exposing Grpc Services with creating **Protobuf messages**
36-
* Using **Dapper for micro-orm implementation** to simplify data access and ensure high performance
37-
* **PostgreSQL database** connection and containerization
35+
* Entity Framework Core ORM — SQLite Data Provider and Migrations to simplify data access and ensure high performance
36+
* **SQLite database** connection and containerization
3837

3938
#### Microservices Communication
4039
* Sync inter-service **gRPC Communication**
@@ -46,33 +45,19 @@ We have implemented below **features over the run-aspnetcore-microservices repos
4645

4746
#### Ordering Microservice
4847
* Implementing **DDD, CQRS, and Clean Architecture** with using Best Practices
49-
* Developing **CQRS with using MediatR, FluentValidation and AutoMapper packages**
48+
* Developing **CQRS with using MediatR, FluentValidation and Mapster packages**
5049
* Consuming **RabbitMQ** BasketCheckout event queue with using **MassTransit-RabbitMQ** Configuration
5150
* **SqlServer database** connection and containerization
5251
* Using **Entity Framework Core ORM** and auto migrate to SqlServer when application startup
5352

54-
#### API Gateway Ocelot Microservice
55-
* Implement **API Gateways with Ocelot**
56-
* Sample microservices/containers to reroute through the API Gateways
57-
* Run multiple different **API Gateway/BFF** container types
58-
* The Gateway aggregation pattern in Shopping.Aggregator
53+
#### Yarp API Gateway Microservice
54+
* Develop API Gateways with **Yarp Reverse Proxy** applying Gateway Routing Pattern
55+
* Yarp Reverse Proxy Configuration; Route, Cluster, Path, Transform, Destinations
56+
* **Rate Limiting** with FixedWindowLimiter on Yarp Reverse Proxy Configuration
5957

6058
#### WebUI ShoppingApp Microservice
6159
* ASP.NET Core Web Application with Bootstrap 4 and Razor template
62-
* Call **Ocelot APIs with HttpClientFactory** and **Polly**
63-
64-
#### Microservices Cross-Cutting Implementations
65-
* Implementing **Centralized Distributed Logging with Elastic Stack (ELK); Elasticsearch, Logstash, Kibana and SeriLog** for Microservices
66-
* Use the **HealthChecks** feature in back-end ASP.NET microservices
67-
* Using **Watchdog** in separate service that can watch health and load across services, and report health about the microservices by querying with the HealthChecks
68-
69-
#### Microservices Resilience Implementations
70-
* Making Microservices more **resilient Use IHttpClientFactory** to implement resilient HTTP requests
71-
* Implement **Retry and Circuit Breaker patterns** with exponential backoff with IHttpClientFactory and **Polly policies**
72-
73-
#### Ancillary Containers
74-
* Use **Portainer** for Container lightweight management UI which allows you to easily manage your different Docker environments
75-
* **pgAdmin PostgreSQL Tools** feature rich Open Source administration and development platform for PostgreSQL
60+
* Call **Yarp APIs with Refit HttpClientFactory**
7661

7762
#### Docker Compose establishment with all microservices on docker;
7863
* Containerization of microservices
@@ -82,8 +67,8 @@ We have implemented below **features over the run-aspnetcore-microservices repos
8267
## Run The Project
8368
You will need the following tools:
8469

85-
* [Visual Studio 2019](https://visualstudio.microsoft.com/downloads/)
86-
* [.Net Core 5 or later](https://dotnet.microsoft.com/download/dotnet-core/5)
70+
* [Visual Studio 2022](https://visualstudio.microsoft.com/downloads/)
71+
* [.Net Core 8 or later](https://dotnet.microsoft.com/download/dotnet-core/8)
8772
* [Docker Desktop](https://www.docker.com/products/docker-desktop)
8873

8974
### Installing
@@ -92,39 +77,18 @@ Follow these steps to get your development environment set up: (Before Run Start
9277
2. Once Docker for Windows is installed, go to the **Settings > Advanced option**, from the Docker icon in the system tray, to configure the minimum amount of memory and CPU like so:
9378
* **Memory: 4 GB**
9479
* CPU: 2
95-
3. At the root directory which include **docker-compose.yml** files, run below command:
80+
3. At the root directory of solution, select **docker-compose** and **Set a startup project**. **Run docker-compose without debugging on visual studio**.
81+
Or you can go to root directory which include **docker-compose.yml** files, run below command:
9682
```csharp
9783
docker-compose -f docker-compose.yml -f docker-compose.override.yml up -d
9884
```
9985

100-
>Note: If you get connection timeout error Docker for Mac please [Turn Off Docker's "Experimental Features".](https://github.com/aspnetrun/run-aspnetcore-microservices/issues/33)
101-
10286
4. Wait for docker compose all microservices. That’s it! (some microservices need extra time to work so please wait if not worked in first shut)
10387

104-
5. You can **launch microservices** as below urls:
105-
106-
* **Catalog API -> http://host.docker.internal:8000/swagger/index.html**
107-
* **Basket API -> http://host.docker.internal:8001/swagger/index.html**
108-
* **Discount API -> http://host.docker.internal:8002/swagger/index.html**
109-
* **Ordering API -> http://host.docker.internal:8004/swagger/index.html**
110-
* **Shopping.Aggregator -> http://host.docker.internal:8005/swagger/index.html**
111-
* **API Gateway -> http://host.docker.internal:8010/Catalog**
112-
* **Rabbit Management Dashboard -> http://host.docker.internal:15672** -- guest/guest
113-
* **Portainer -> http://host.docker.internal:9000** -- admin/admin1234
114-
* **pgAdmin PostgreSQL -> http://host.docker.internal:5050** -- admin@aspnetrun.com/admin1234
115-
* **Elasticsearch -> http://host.docker.internal:9200**
116-
* **Kibana -> http://host.docker.internal:5601**
117-
118-
* **Web Status -> http://host.docker.internal:8007**
119-
* **Web UI -> http://host.docker.internal:8006**
120-
121-
5. Launch http://host.docker.internal:8007 in your browser to view the Web Status. Make sure that every microservices are healthy.
122-
6. Launch http://host.docker.internal:8006 in your browser to view the Web UI. You can use Web project in order to **call microservices over API Gateway**. When you **checkout the basket** you can follow **queue record on RabbitMQ dashboard**.
88+
5. Launch **Shopping Web UI -> https://localhost:6065** in your browser to view index page. You can use Web project in order to **call microservices over Yarp API Gateway**. When you **checkout the basket** you can follow **queue record on RabbitMQ dashboard**.
12389

12490
![mainscreen2](https://user-images.githubusercontent.com/1147445/81381837-08226000-9116-11ea-9489-82645b8dbfc4.png)
12591

126-
>Note: If you are running this application in macOS then use `docker.for.mac.localhost` as DNS name in `.env` file and the above URLs instead of `host.docker.internal`.
127-
12892
## Authors
12993

13094
* **Mehmet Ozkaya** - *Initial work* - [mehmetozkaya](https://github.com/mehmetozkaya)

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /