Handling orders

As mentioned earlier, receiving an order is not just a matter of writing a row in a database. In real-world scenarios, an incoming e-commerce order triggers several business procedures. Some of them are as follows:

  • Notifying the warehouse set for the delivery
  • Notifying the sales agent to perform appropriate actions on the CRM
  • Notifying payment information to the financial department

We can achieve these with two opposite approaches:

  • Push approach: The application receiving an order "pushes" the notification to the involved systems
  • Pull approach: The involved systems periodically checks for changes into a specific place in order to start business rules

Both approaches have advantages/disadvantages. They are explained in the following table: ...

Get Mastering Cloud Development using Microsoft Azure now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.