[英]Is this the correct way/structure of DDD implementation in ASP.NET Core?
this may not be the place to ask, but since I am very new at this, can you please tell me if this is the correct way of structuring Domain-Driven-Design in ASP.NET Core.这可能不是要问的地方,但是由于我对此很陌生,请告诉我这是否是在 ASP.NET 内核中构建域驱动设计的正确方法。
To be more specific the way I structured it is based on official Microsoft documentation site.更具体地说,我构建它的方式是基于官方的 Microsoft 文档站点。
Depo.API representing Application Layer referencing Depo.Domain and Depo.Infrastructure Depo.API表示引用Depo.Domain和Depo.Infrastructure 的应用层
Depo.Infrastructure referencing Depo.Domain only. Depo.Infrastructure仅引用Depo.Domain 。
Depo.Domain being the core of application. Depo.Domain是应用程序的核心。
Please let me know or suggest me anything, and I apologize if this doesn't meet the community guidelines.请让我知道或向我提出任何建议,如果这不符合社区准则,我深表歉意。
I think your implementation is almost correct, but to improve the architecture you can add a layer called SERVICE layer to implement Business Logic.我认为您的实现几乎是正确的,但是为了改进架构,您可以添加一个称为 SERVICE 层的层来实现业务逻辑。 Also, move the Validators and Mapper to the Infrastructure layer.
此外,将 Validators 和 Mapper 移至 Infrastructure 层。 The entire API layer contains only controllers and startup settings.
整个 API 层仅包含控制器和启动设置。 also You can also use the following link: docs.microsoft.com reference
您还可以使用以下链接: docs.microsoft.com 参考
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.