Microservices organizes an application into services that can be developed and deployed independently around business capabilities. Each service runs separately and communicates through a network API or messages. A service is a business boundary, not simply one endpoint or one database table.
Understand the main parts
For an online shop, Orders owns order status, Inventory owns stock, and Payments owns payment records. A gateway may route incoming requests, but it is optional. A message broker may carry asynchronous messages when the receiving service need not respond immediately.
Client -> Orders service -> Orders data
| network call
+-> Inventory service -> Inventory data
+-> Payments service -> Payments data
