Question 1
Topic: Cloud Native Fundamentals
Skill tested: Select microservices, containers, or functions based on workload execution and scaling needs.
A logistics company is decomposing a shipment platform. One component consumes short bursts of queue messages, performs a stateless validation, and then exits. Traffic is unpredictable, each message can be processed independently, and the team wants to avoid maintaining an always-running service. Another component must maintain long-lived WebSocket connections and coordinate in-memory sessions with a low-latency cache. Which design best fits the first component without constraining the second component's architecture?
The queue validator is brief, stateless, and invoked in unpredictable bursts, which suits an event-driven function and avoids provisioning an always-on application service. Long-lived WebSocket connections and session coordination are better handled by a persistent containerized service designed to maintain connections and integrate with the cache. Running both as functions does not suit the persistent connection requirement; running both in OKE adds unnecessary always-on management for the bursty validator. The final choice reverses the workload fit.