Design & Architecture with SOA,Services & Microservices
What this topic covers
Shape services around owned business capabilities, such as catalog, inventory, pricing, and orders. Apply loose coupling, abstraction, and reusable contracts while keeping business invariants with the service that owns them.
Which service should calculate the amount due for an order, pricing or order management?
Pricing owns the calculation of the amount due, while order management owns the purchase lifecycle state such as pending or confirmed. Keeping those responsibilities apart means each service enforces its own rules over its own data. Order management asks pricing for the total rather than computing it itself.