An e-commerce company wants to resize product images, update inventory, and send confirmation messages whenever an order event occurs. The architects need a design that immediately invokes three separate microservices in parallel so each task runs independently, avoiding a single bottleneck and reducing overall response time. Which cloud-native approach best meets these requirements?
Invoke each microservice sequentially from an API workflow that waits for every response before returning a result.
Run a nightly batch job on one server that performs resizing, inventory updates, and notifications in a fixed order.
Place the event on a single queue serviced by one worker process that forwards results to the other microservices afterward.
Publish the order event to a message topic that fans out a copy to each subscribed microservice, allowing all three to run in parallel.
Publishing the event to a topic that fans out a copy to every subscribed endpoint implements the fan-out pattern. Each microservice receives the same event and processes it concurrently, maximizing throughput. A synchronous workflow calls the services one after another, creating latency. A single batch job keeps all work on one server, limiting scalability. A single-consumer queue processes events serially and can become a bottleneck.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What is an event-based pattern in distributed systems?
Open an interactive chat with Bash
How does parallelization improve processing speed?
Open an interactive chat with Bash
Why is a single synchronous workflow not ideal for concurrency?