- Java EE 8 and Angular
- Prashant Padmanabhan
- 185字
- 2021-07-02 19:22:38
Follow domain-driven design
Focus on the responsibility that the microservice is trying to meet. The scope of the service is more important than the lines of code used to build it. Teams would usually sit together and build an understanding of the domain from the domain experts. Once the domain is understood, then it is modeled as domain objects, which can be further grouped as sub-domains. In a monolith, the entire domain model is within a single application, but the microservice architecture would lead your domains to be used within different business contexts.
Bounded Contexts is a term used in DDD, which maps the domain entities within the context of its usage. A payment microservice might require a domain entity such as User, to be used for billing purposes, and thus the User entity may need to have payment details associated with it. But if the same domain entity is used in a notification service, then the payment information is an additional detail, which shouldn't get leaked into this service.
The idea of a bounded context is further explained in the section on Single Responsibility.
- C語言程序設計案例教程
- JavaScript高效圖形編程
- INSTANT OpenCV Starter
- JavaScript修煉之道
- 動手玩轉Scratch3.0編程:人工智能科創教育指南
- JavaScript by Example
- Apache Mesos Essentials
- 從Excel到Python:用Python輕松處理Excel數據(第2版)
- 自然語言處理Python進階
- 深入淺出PostgreSQL
- C++面向對象程序設計習題解答與上機指導(第三版)
- PySide 6/PyQt 6快速開發與實戰
- PHP從入門到精通(第4版)(軟件開發視頻大講堂)
- Terraform:多云、混合云環境下實現基礎設施即代碼(第2版)
- ArcGIS for Desktop Cookbook