TNO – DynAA: discrete-event simulation engine for the computing continuum
| ID: R16 | Licence: Apache 2.0 |
Owner: TNO |
Contacts: julio.deoliveirafilho@tno.nl |
| Short Description | DynAA is a highly efficient system simulation engine based on discrete event specifications. In MYRTUS it simulates edge-fog-cloud topologies described in TOSCA, estimating resource utilization, latency and power dissipation at design time, and it is used at run time by the DCOP-based Workload Manager to evaluate candidate allocations of software components. |
| Key features | – Fast, low-footprint simulation of combined software execution profiles – System-wide description of the continuum, including compute nodes, memory, network connections and software components at all levels – Simulation of the interconnection between nodes and of the effects of data exchanges, such as bandwidth limitations and message transfers – Able to serve as a digital twin of a continuum deployment, enabling analysis, estimation and optimization – Simulation scenarios described in a dedicated schema, into which TOSCA descriptions can be transformed almost directly – Simulation offered as a service through a REST API (NexusSim Server) – Simulations can be parallelized in HPC or cloud for accelerated evaluations |
| Require | Not applicable. |
| Provide | – (Custom) Detailed simulation traces of system and compound software component behaviours – Estimation of system KPIs, extracted from trace analysis – A service interface through which external tools can submit simulation scenarios, monitor their execution and retrieve the results |
| Input | – Characterization of software component resource utilization and behaviour in advance (workload profiles) – Description of the current status and configuration of the system: compute and network resources, software components and their allocation to compute nodes, for example derived from a TOSCA model exported with Modelio TOSCA Designer |
| Output | – (Custom) Detailed simulation traces of system and compound software component behaviours – Estimation of system KPIs, extracted from trace analysis: an application profile with data points on resource utilization, latency and power dissipation |
| User | In the MYRTUS context, application developers and system architects in Step 1 of the MYRTUS DPE, and the DCOP-based Workload Manager, where SAM, a DCOP optimization engine, uses DynAA to evaluate the system KPIs of possible solutions during space exploration. More broadly, DevOps teams, software architects, cloud engineers and platform owners who deploy services on cloud, platform-as-a-service or edge infrastructures. |
| Benefits for the user | Quantitative analysis, reasoning and optimization for the workload orchestration process, both at design time and at run time. Performance is predicted before deployment, so that resource allocation can be optimized and wrong performance assumptions are found before they turn into costs. |
| Download | Simulation engine: github.com/TNO/cDynAA Continuum models: github.com/TNO/nexussim Simulation service: github.com/TNO/nexussim-server |
| Role in MYRTUS | Step 1 of the MYRTUS DPE (Continuum modelling, simulation and analysis): simulation of the modelled topology and generation of the application profile. Also used at run time in the MIRTO cognitive engine, by the DCOP-based Workload Manager. |
| TRL@M0 | 5-6 |
| TRL@M36 | 5-6 |
General description
DynAA is a discrete-event simulation framework for modelling and analyzing complex distributed systems. It was originally developed at TNO, in other projects, as a reusable simulation infrastructure for distributed and communication-intensive applications, and has evolved over several years of research and development: it is therefore a mature software module that already existed before MYRTUS. It provides an efficient event scheduling mechanism and a modular architecture, so that simulations can be built from reusable components.
The engine is written in C++ and is highly performant and memory efficient: it is designed to keep the footprint of the simulation models to a minimum, so that it can simulate computing systems with behavioural models of thousands of independent machines, software components and network connections. During the simulation these models interact to emulate resource usage and power consumption over time; by analyzing the simulation traces, users can visualize and estimate metrics such as CPU and memory usage, network activity and the interactions between software components. A Python integration wrapper, pyDynAA, eases the integration with prototypes and simulations driven from Python.
Role in the MYRTUS DPE
In Step 1 of the MYRTUS DPE, an application that is still at the level of requirements and existing software components is turned into a topology model that can be simulated, tuned and handed over to the following steps. The topology, with the relationships between nodes and the policies and constraints of the application, is modelled in TOSCA with Modelio TOSCA Designer, and the model is then handed to DynAA, which simulates it.
A TOSCA description can be transformed almost directly into the DynAA simulation schema, which describes the compute nodes, the networks connecting them, the software components, their allocation to the compute nodes and the flow of the application, that is, how and when each component sends data to the others. The simulation produces an application profile, a set of data points on resource utilization, latency and power dissipation. The user inspects it to find bottlenecks and decide whether the TOSCA model needs to be revised, in an iterative loop of modelling, simulation and analysis; the profile is also passed, together with the TOSCA model, to the design space exploration block for large-scale deployments and to Step 2 of the DPE.
The design space exploration block can use simulation to evaluate the candidate solutions of evolutionary methods such as FREVO. An integration of FREVO with DynAA was considered for this purpose, but it was not needed, since FREVO is paired with COSMOS.
Role in the MIRTO cognitive engine
DynAA is not only a design-time tool. The core orchestration task of the MIRTO cognitive engine is to find a (quasi-)optimal mapping of software components onto the compute nodes of the continuum: a combinatorial problem whose objectives are usually not expressed in analytical form, but evaluated through simulation or measurement. In the DCOP-based Workload Manager, the SAM toolbox explores the possible allocations and relies on DynAA to estimate the effect of each of them.
For each scenario prospected by the Workload Manager, an interface describes it and transfers it to DynAA, which translates it into a simulation of the continuum, analyzes the resulting traces in terms of KPIs, mainly CPU and memory utilization across the system, and reports the estimates back to SAM to drive the orchestration decisions. Several properties make DynAA suitable for this role: the event-based system is loosely coupled, so components can be added or removed dynamically; the optimized engine runs simulations with very little overhead; and the level of detail can be mixed, modelling some aspects in depth and others only through basic interactions.
To compute the KPIs, DynAA needs the description of the compute and network resources and of the behaviour of the software components. These workload profiles are provided during the development phase through the Distributed Knowledge Base, and their preparation is supported by the workload characterization methods and monitoring tools developed in MYRTUS. When a detailed profile is not available, the Workload Manager falls back on a simplified model based only on the requirements declared in the service chain.
MYRTUS Extension/Contribution
Within MYRTUS, DynAA has been extended to model continuum infrastructures and to be integrated with the other tools of the DPE and of the cognitive engine:
- Domain layer: a domain-specific layer, the NexusSim framework, that models the components of the continuum, including computing machines with their CPUs and memory, network connections and software components, so that system resources, application workloads and their interactions can be described at a higher level of abstraction.
- Simulation schema: a data format to describe and configure simulation setups, specifying how components are created and parameterized, how they are interconnected (for example the network topology), the temporal behaviour of the software modules and their mapping to execution environments.
- Front-end integration: a front-end that transforms a simulation description written in the schema into a functional simulation model.
- Memory and network models: new models for memory consumption and memory-related constraints, and for communication links, message transfers, bandwidth limitations and routing, so that simulations capture not only computation, but also the communication and memory effects that often dominate performance in distributed edge-fog-cloud systems.
- Simulation as a service: the NexusSim Server exposes the simulation capabilities through a REST API, through which external tools can submit scenarios, monitor their execution and retrieve the results, without integrating directly with the simulation framework.
- Coupling with SAM: the interface through which the DCOP-based Workload Manager transfers prospected scenarios to DynAA and receives the estimated KPIs.
The core engine, the continuum models and the simulation server have been released as open-source repositories during MYRTUS.
Technology Benefits and Innovations
DynAA lets the behaviour of large distributed applications spanning cloud, fog and edge be evaluated before they are deployed. Orchestration strategies, scheduling approaches and deployment alternatives can be compared in simulation, including resource-constrained environments, communication-intensive workloads and geographically distributed deployments, instead of relying on manual configuration and trial-and-error deployments.
Separating the simulation engine from its service interface turns simulation into a reusable service rather than a standalone tool: candidate deployment configurations generated by optimization algorithms can be evaluated before execution, and workload management and orchestration components can assess the impact of their decisions at run time. Thanks to its efficiency and to the possibility of mixing levels of detail, the same engine supports both design-time exploration and time-critical runtime decision support.
Predicting performance before deployment also reduces the risks of deciding on wrong assumptions, which can lead either to oversized and costly infrastructures or to services that do not meet their requirements. Simulation makes it possible to check whether compute-intensive algorithms, such as machine learning workloads, can actually be deployed on a given infrastructure, to optimize the allocation of resources, and to give infrastructure providers a sound basis for the service levels they commit to when hosting complex systems-of-systems and cyber-physical systems.
Users
DevOps teams, software architects and cloud engineers, in enterprises or R&D groups, who deploy services, including cyber-physical systems, on cloud, platform-as-a-service or edge infrastructures. They can use DynAA to estimate the resource usage, latency and power consumption of distributed applications before deployment, to check whether demanding algorithms can run on the available resources, and to plan deployments that meet their service-level agreements at a reasonable cost. Platform owners that host services for others can use the same estimates to dimension their infrastructure and define the service levels they offer. Developers of orchestrators, schedulers and optimization algorithms can use DynAA, through its service interface, as an evaluator of candidate deployments, and researchers can build on the open-source engine and continuum models to study deployment strategies in large-scale scenarios.
References
- J. O. de Filho, T. Vogel, J. de Gier, Runtime Services and Tooling for Reconfiguration, Springer, 2016.
- Code: github.com/TNO/cDynAA, github.com/TNO/nexussim, github.com/TNO/nexussim-server