## 4 Variable Deployment Models
### Variable Deployment Metamodel  
This section introduces the _Variable Deployment Metamodel (VDMM)_, which is based on EDMM introduced by [PERSON] et al. [1]. In the following, we first explain the underlying EDMM and introduce the required extensions for variability afterward. EDMM defines a metamodel for declarative deployment models which was the result of an analysis of the most prominent declarative deployment technologies, including Terraform [7], Puppet [8], Kubernetes [9], and Ansible [10]. EDMM contains only modeling elements that can be mapped to all of these technologies, thus providing the greatest common denominator of all these technologies. Since our approach is based on EDMM, the approach can also be applied to these technologies. EDMM defines declarative deployment models in the form of a directed graph in which typed components are represented as colored nodes and typed relations as weighted edges. Figure 4 contains the class diagram of EDMM in the form of white boxes. Please note that this class diagram does not show the entire EDMM but only the classes required for our approach. For example, we omit the definition of _Operations_ that are, for example, responsible for provisioning and configuring a component. Figure 4: Class diagram of VDMM based on EDMM (EDMMM original classes in white, added classes for variability in grey). Figure 3: Variable Deployment Model of our motivating scenario. VDMM extends EDMM with classes for variability modeling which are rendered as grey boxes in Figure 4. A Variable Deployment Model represents all possible deployment variants. A deployment variant is defined as \(d_{i}\in D_{vdm}\), where \(D_{vdm}\) is the set of all executable deployment models that can be derived from a Variable Deployment Model \(vdm\in\mathcal{VDM}\), where \(\mathcal{VDM}\) is the set of all Variable Deployment Models. Let \(\mathcal{VDM}\) be the set of all Variable Deployment Models, then \(vdm\in\mathcal{VDM}\) is defined as a tuple as follows:  
\[ \begin{split} vdm=&(C_{vdm},R_{vdm},CT_{vdm},RT_{ vdm},type_{vdm},P_{vdm},properties_{vdm},VI_{vdm},\\ & CON_{vdm},inputs_{vdm},G_{vdm},conditions_{vdm},evaluate_{vdm}) \end{split}  \tag{1}\]  
We first describe the classes of EDMM as defined by [PERSON] et al. [1]. These classes provide the basis for declarative deployment models. * \(C_{vdm}\) is the set of _Components_ in \(vdm\). Each \(c_{i}\in C_{vdm}\) represents a component of the application. Considering our motivating scenario, the components \"Web Component\", \"Dev Runtime\", and \"Private VM\", for example, belong to this set. * \(R_{vdm}\subseteq C_{vdm}\times C_{vdm}\) is the set of _Relations_ between two components in \(vdm\). Each \(r_{i}=(c_{s},c_{t})\in R_{vdm}\) represents a relationship between two components of the application, whereby \(c_{s}\) is the _Source_ and \(c_{t}\) the _Target Component_. Considering our motivating scenario, the hosting relation between the (source) component \"Web Component\" and (target) component \"Dev Runtime\", for example, is such a relationship. * \(CT_{vdm}\) is the set of _Component Types_ in \(vdm\). Each \(ct_{i}\in CT_{vdm}\) describes the semantics of a component having this type. Considering our motivating scenario, the component \"Web Component\", for example, has the type \"Nodejs14 App\" which describes, for example, that a hosting relation is required. * \(RT_{vdm}\) is the set of _Relation Types_ in \(vdm\). Each \(rt_{i}\in RT_{vdm}\) describes the semantics for each relation having this type. Considering our motivating scenario, the relation between the components \"Web Component\" and \"Dev Runtime\", for example, is of type \"hostedOn\" and describes that the component \"Web Component\" is running on the component \"Dev Runtime\". * The set of _Typed Elements_\(E_{vdm}:=C_{vdm}\cup R_{vdm}\) is the union set of components and relations in \(vdm\). Considering our motivating scenario, the components \"Web Component\" and \"Dev Runtime\", for example, along with their hosting relation belong to this set.