{"id":15675409,"url":"https://github.com/thangchung/practical-dotnet-aspire","last_synced_at":"2025-06-18T01:34:36.529Z","repository":{"id":221797191,"uuid":"732275752","full_name":"thangchung/practical-dotnet-aspire","owner":"thangchung","description":"The practical .NET Aspire builds on the coffeeshop app business domain","archived":false,"fork":false,"pushed_at":"2025-02-06T04:10:41.000Z","size":746,"stargazers_count":390,"open_issues_count":17,"forks_count":59,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-04-30T22:49:38.316Z","etag":null,"topics":["dotnet","dotnet-aspire","marten","masstransit"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thangchung.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-12-16T06:05:47.000Z","updated_at":"2025-04-28T12:11:31.000Z","dependencies_parsed_at":"2024-02-10T07:24:13.126Z","dependency_job_id":"f49780f1-f2d4-4e4c-8c33-fb8c6c1e85ef","html_url":"https://github.com/thangchung/practical-dotnet-aspire","commit_stats":null,"previous_names":["thangchung/coffeeshop-aspire","thangchung/practical-dotnet-aspire"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/thangchung/practical-dotnet-aspire","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thangchung%2Fpractical-dotnet-aspire","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thangchung%2Fpractical-dotnet-aspire/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thangchung%2Fpractical-dotnet-aspire/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thangchung%2Fpractical-dotnet-aspire/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thangchung","download_url":"https://codeload.github.com/thangchung/practical-dotnet-aspire/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thangchung%2Fpractical-dotnet-aspire/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260468321,"owners_count":23013884,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dotnet","dotnet-aspire","marten","masstransit"],"created_at":"2024-10-03T15:59:55.549Z","updated_at":"2025-06-18T01:34:31.494Z","avatar_url":"https://github.com/thangchung.png","language":"C#","funding_links":[],"categories":["dotnet","Example projects"],"sub_categories":[],"readme":"# The Coffeeshop Apps on .NET Aspire\n\nThe coffeeshop apps on .NET Aspire\n\n![Counter API-Code Coverage](https://img.shields.io/badge/Code%20Coverage-73%25-yellow?style=flat)\n\n## Get starting\n\nIn `Visual Studio` with the project opening, press `F5`!!!\n\nor \n\n```sh\n\u003e dotnet build coffeeshop-aspire.sln\n\u003e dotnet run --project app-host/CoffeeShop.AppHost.csproj\n# http://localhost:5019\n```\n\n## Introduction\n\n\u003e Notice: This is just a demo of how can we build and deploy the microservices approach. In the reality, the boundary should be defined by bounded-context concepts of Domain-driven Design, and totally based on the business domain, and might not be so fine-grained services like this demo, so you use it with care.\n\n- [x] Built on .NET 9.0 STS\n- [x] .NET Aspire 9\n- [x] Microservices architectural style\n- [x] Follows Vertical Sliding principles\n- [x] Domain Driven Design building blocks\n- [x] CQRS with MediatR and Fluent Validations\n- [x] Shift-left Observability with .NET Aspire (OpenTelemetry built-in)\n\t- [x] Custom OpenTelemetry for MediatR and FluentValidation handlers\n\t- [x] Custom OpenTelemetry for MassTransit on consumers\n\t- [x] Enrich .NET 8 global loggings\n- [x] OpenAPI supports\n- [x] Mapperly for generating object mappings\n- [x] API Versioning\n- [x] Integration test with .NET Aspire and Wiremock.NET\n\t- [x] Run it on GitHub Actions and output code coverage\n- [x] UUID v7\n\t- [Extend System.Guid with a new creation API for v7](https://github.com/dotnet/runtime/issues/103658)\n\t- [Npgsql.EntityFrameworkCore.PostgreSQL-UUIDv7 GUIDs are generated by default](https://www.npgsql.org/efcore/release-notes/9.0.html#uuidv7-guids-are-generated-by-default)\n- [x] Microsoft.Extensions.AI (Ollama for local dev and Azure OpenAI service) \n- [ ] Response Caching - Distributed Caching with Redis\n- [ ] JWT \u0026 Authentication with ASP.NET Identity\n\n## System Context diagram - C4 Model\n\n```mermaid\nC4Context\n\ttitle System Context diagram for CoffeeShop Application\n\tBoundary(b0, \"Boundary1\") {\n\t\tPerson(customer, \"Customers\", \"Customers of the coffeeshop.\")\n\n\t\tBoundary(b1, \"Application\", \"boundary\") {\n\t\t\tSystem(SystemA, \"CoffeeShop app\", \"Allows customers to submit and view their orders.\")\n\t\t}\n\n\t\tBoundary(b2, \"Infrastructure\", \"boundary\") {\n\t\t\tSystemDb(SystemD, \"Database\", \"A system of the coffeeshop app.\")\n\t\t\tSystemQueue(SystemQ, \"Message Queue\", \"A system of the coffeeshop app.\")\n\t\t}\n\t}\n\n\tRel(customer, SystemA, \"Uses\")\n\tRel(SystemA, SystemD, \"Uses\")\n\tRel(SystemA, SystemQ, \"Uses\")\n```\n\n## Container diagram - C4 Model\n\n```mermaid\nC4Container\n\ttitle Container diagram for CoffeeShop Application\n\n\tPerson(customer, \"Customers\", \"Customers of the coffeeshop.\")\n\n\tContainer_Boundary(c1, \"CoffeeShop Application\") {\n\t\tContainer(reverse_proxy, \"Gateway\", \"C#, .NET 8, YARP\", \"The reverse proxy/API gateway of the coffeeshop app.\")\n\n\t\tContainer(counter_api, \"Counter APIs\", \"C#, .NET 8, MassTransit\", \"The counter service.\")\n\t\tContainer(barista_api, \"Barista APIs\", \"C#, .NET 8, MassTransit\", \"The barista service.\")\n\t\tContainer(kitchen_api, \"Kitchen APIs\", \"C#, .NET 8, MassTransit\", \"The kitchen service.\")\n\t\tContainer(order_summary, \"Order Summary\", \"C#, .NET 8, Marten\", \"The order summary service.\")\n\n\t\tContainer(product_api, \"Product APIs\", \"C#, .NET 8\", \"The product service.\")\n\t\t\n\t\tBoundary(b1, \"Docker containers\", \"boundary\") {\n\t\t\tContainerDb(database, \"Database\", \"Postgres\", \"Stores orders, audit logs, etc.\")\n\t\t\tContainerQueue(message_broker, \"Message Broker\", \"RabbitMQ\", \"Asynchronous communication between counter, barista, kitchen, and order-summary\")\n\t\t}\n\t}\n\n\tRel(customer, reverse_proxy, \"Uses\", \"HTTPS\")\n\t\n\tRel(reverse_proxy, product_api, \"Proxies\", \"HTTP\")\n\tRel(reverse_proxy, counter_api, \"Proxies\", \"HTTP\")\n\n\tRel(order_summary, database, \"Uses\", \"TCP\")\n\t\n\tRel(counter_api, product_api, \"Calls\", \"HTTP\")\n\tRel(counter_api, message_broker, \"Publishes\", \"TCP\")\n\tRel(counter_api, message_broker, \"Publishes\", \"TCP\")\n\t\n\tRel_Back(barista_api, message_broker, \"Subscribes\", \"TCP\")\n\tRel_Back(kitchen_api, message_broker, \"Subscribes\", \"TCP\")\n\tRel_Back(order_summary, message_broker, \"Subscribes\", \"TCP\")\n```\n\n## CoffeeShop App Infused with AI - Intelligent Apps Development\n\n### Seeding data - chat completion\n\n![](assets/genai_seed_data.png)\n\n### Semantic Searching - vector embeddings\n\n![](assets/genai_semantic_searching.png)\n\nThe detail blog of how to implement it at https://dev.to/thangchung/coffeeshop-app-infused-with-ai-intelligent-apps-development-202k\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthangchung%2Fpractical-dotnet-aspire","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthangchung%2Fpractical-dotnet-aspire","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthangchung%2Fpractical-dotnet-aspire/lists"}