The `Simulation Engine` subsystem is the core orchestrator of the simulation, responsible for building, wiring, and starting all simulation actors, managing the simulation clock, and initiating the metric collection process. It drives the overall simulation lifecycle.
Components
Simulation Engine (Orchestrator)
The central orchestrator of the simulation, responsible for managing the entire simulation lifecycle. This includes coordinating the building and configuration of all simulation actors, establishing communication channels and network topology, initiating the execution of all simulation processes, and starting the metric collection mechanisms. It acts as the primary entry point for running a simulation.
Referenced Source Code
Actor Builder
Responsible for instantiating and configuring various simulation actors such as clients, servers, load balancers, and request generators based on the simulation's configuration. It translates configuration details into concrete simulation entities.
Referenced Source Code
Communication Channel Manager
Manages the creation and configuration of inboxes or message queues that facilitate inter-actor communication within the simulated environment, enabling the "Interconnected Components" aspect of the architecture.
Referenced Source Code
Edge Builder
Establishes the network topology and defines the connections (edges) between different simulation actors, determining how requests and messages flow through the system. This is vital for simulating distributed system interactions.
Referenced Source Code
Process Starter
Initiates and manages the execution of all individual simulation processes (e.g., client request generation, server processing, load balancer routing) within the SimPy discrete event simulation environment.
Referenced Source Code
Metric Collector Starter
Activates and configures the mechanisms responsible for collecting various performance and operational metrics throughout the simulation run, enabling the "Observability" aspect of the architecture.