diff --git a/docs/reference_index.rst b/docs/reference_index.rst index ea6fe70bac0a9cce4487e1af14f17256434fa82e..435655e9dbba50e09fd7ac60777f44d063ae46cb 100644 --- a/docs/reference_index.rst +++ b/docs/reference_index.rst @@ -9,3 +9,7 @@ For a comprehensive list of all the classes, attributes and associations support ----------------------------------------------- :doc:`Reference for DOML v2.2 <reference_v2.2>` ----------------------------------------------- +:doc:`Reference for DOML v2.2.1 <reference_v2.2.1>` +--------------------------------------------------- +:doc:`Reference for DOML v2.3 <reference_v2.3>` +----------------------------------------------- diff --git a/docs/reference_v2.2.1.rst b/docs/reference_v2.2.1.rst new file mode 100644 index 0000000000000000000000000000000000000000..3fe713a1e1d66ec784453e6ad46317cd86b6d6ac --- /dev/null +++ b/docs/reference_v2.2.1.rst @@ -0,0 +1,588 @@ +DOML v2.2.1 Reference +============================= + + +commons +^^^^^^^ + +.. _v2.2.1_commons_BProperty: + +BProperty +""""""""" +*Inherits from* :ref:`Property <v2.2.1_commons_Property>` + +* Attributes: + * ``value`` [Boolean] + +.. _v2.2.1_commons_Configuration: + +Configuration +""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``deployments`` → Deployment [0..*] + +.. _v2.2.1_commons_Credentials: + +Credentials +""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + + +.. _v2.2.1_commons_DOMLElement: + +DOMLElement +""""""""""" +* Associations: + * ``annotations`` → Property [0..*] +* Attributes: + * ``name`` [String] + * ``description`` [String] + +.. _v2.2.1_commons_DeployableElement: + +DeployableElement +""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + + +.. _v2.2.1_commons_Deployment: + +Deployment +"""""""""" +* Associations: + * ``component`` → DeployableElement [1..1] + * ``node`` → InfrastructureElement [1..1] + +.. _v2.2.1_commons_FProperty: + +FProperty +""""""""" +*Inherits from* :ref:`Property <v2.2.1_commons_Property>` + +* Attributes: + * ``value`` [String] + +.. _v2.2.1_commons_IProperty: + +IProperty +""""""""" +*Inherits from* :ref:`Property <v2.2.1_commons_Property>` + +* Attributes: + * ``value`` [Integer] + +.. _v2.2.1_commons_KeyPair: + +KeyPair +""""""" +*Inherits from* :ref:`Credentials <v2.2.1_commons_Credentials>` + +* Attributes: + * ``user`` [String] + * ``keyfile`` [String] + * ``algorithm`` [String] + * ``bits`` [Integer] + +.. _v2.2.1_commons_Property: + +Property +"""""""" +* Associations: + * ``reference`` → DOMLElement [0..1] +* Attributes: + * ``key`` [String] + +.. _v2.2.1_commons_SProperty: + +SProperty +""""""""" +*Inherits from* :ref:`Property <v2.2.1_commons_Property>` + +* Attributes: + * ``value`` [String] + +.. _v2.2.1_commons_Source: + +Source +"""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Attributes: + * ``entry`` [String] + * ``backend`` [String] + +.. _v2.2.1_commons_UserPass: + +UserPass +"""""""" +*Inherits from* :ref:`Credentials <v2.2.1_commons_Credentials>` + +* Attributes: + * ``username`` [String] + * ``password`` [String] + +application +^^^^^^^^^^^ + +.. _v2.2.1_application_ApplicationComponent: + +ApplicationComponent +"""""""""""""""""""" +*Inherits from* :ref:`DeployableElement <v2.2.1_commons_DeployableElement>` + + +.. _v2.2.1_application_ApplicationLayer: + +ApplicationLayer +"""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``components`` → ApplicationComponent [0..*] + +.. _v2.2.1_application_DBMS: + +DBMS +"""" +*Inherits from* :ref:`SoftwareComponent <v2.2.1_application_SoftwareComponent>` + + +.. _v2.2.1_application_SaaS: + +SaaS +"""" +*Inherits from* :ref:`ApplicationComponent <v2.2.1_application_ApplicationComponent>` + +* Associations: + * ``exposedInterfaces`` → SoftwareInterface [0..*] +* Attributes: + * ``licenseCost`` [String] + +.. _v2.2.1_application_SaaSDBMS: + +SaaSDBMS +"""""""" +*Inherits from* :ref:`SaaS <v2.2.1_application_SaaS>` + + +.. _v2.2.1_application_SoftwareComponent: + +SoftwareComponent +""""""""""""""""" +*Inherits from* :ref:`ApplicationComponent <v2.2.1_application_ApplicationComponent>` + +* Associations: + * ``exposedInterfaces`` → SoftwareInterface [0..*] + * ``consumedInterfaces`` → SoftwareInterface [0..*] + * ``src`` → Source [0..1] +* Attributes: + * ``isPersistent`` [Boolean] + * ``licenseCost`` [String] + +.. _v2.2.1_application_SoftwareInterface: + +SoftwareInterface +""""""""""""""""" +*Inherits from* :ref:`ApplicationComponent <v2.2.1_application_ApplicationComponent>` + +* Attributes: + * ``endPoint`` [String] + +infrastructure +^^^^^^^^^^^^^^ + +.. _v2.2.1_infrastructure_AutoScalingGroup: + +AutoScalingGroup +"""""""""""""""" +*Inherits from* :ref:`ComputingGroup <v2.2.1_infrastructure_ComputingGroup>` + +* Associations: + * ``machineDefinition`` → VirtualMachine [1..1] + * ``securityGroup`` → SecurityGroup [0..1] +* Attributes: + * ``min`` [Integer] + * ``max`` [Integer] + * ``loadBalancer`` [String] + +.. _v2.2.1_infrastructure_ComputingGroup: + +ComputingGroup +"""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``groupedNodes`` → ComputingNode [0..*] + +.. _v2.2.1_infrastructure_ComputingNode: + +ComputingNode +""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.2.1_infrastructure_InfrastructureElement>` + +* Associations: + * ``ifaces`` → NetworkInterface [0..*] + * ``location`` → Location [0..1] + * ``credentials`` → Credentials [0..1] + * ``group`` → ComputingGroup [0..1] +* Attributes: + * ``architecture`` [String] + * ``os`` [String] + * ``memory_mb`` [Integer] + * ``memory_kb`` [Integer] + * ``storage`` [String] + * ``cpu_count`` [Integer] + * ``cost`` [Integer] + * ``disabledMonitorings`` [String] + +.. _v2.2.1_infrastructure_ComputingNodeGenerator: + +ComputingNodeGenerator +"""""""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Attributes: + * ``uri`` [String] + * ``kind`` [GeneratorKind] + +.. _v2.2.1_infrastructure_Container: + +Container +""""""""" +*Inherits from* :ref:`ComputingNode <v2.2.1_infrastructure_ComputingNode>` + +* Associations: + * ``generatedFrom`` → ContainerImage [0..1] + * ``configs`` → ContainerConfig [0..*] + +.. _v2.2.1_infrastructure_ContainerConfig: + +ContainerConfig +""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``host`` → ComputingNode [0..1] + * ``iface`` → NetworkInterface [0..1] +* Attributes: + * ``container_port`` [Integer] + * ``vm_port`` [Integer] + +.. _v2.2.1_infrastructure_ContainerImage: + +ContainerImage +"""""""""""""" +*Inherits from* :ref:`ComputingNodeGenerator <v2.2.1_infrastructure_ComputingNodeGenerator>` + +* Associations: + * ``generatedContainers`` → Container [0..*] + +.. _v2.2.1_infrastructure_ExtInfrastructureElement: + +ExtInfrastructureElement +"""""""""""""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.2.1_infrastructure_InfrastructureElement>` + + +.. _v2.2.1_infrastructure_FunctionAsAService: + +FunctionAsAService +"""""""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.2.1_infrastructure_InfrastructureElement>` + +* Associations: + * ``ifaces`` → NetworkInterface [0..*] +* Attributes: + * ``cost`` [Integer] + +.. _v2.2.1_infrastructure_InfrastructureElement: + +InfrastructureElement +""""""""""""""""""""" +*Inherits from* :ref:`DeployableElement <v2.2.1_commons_DeployableElement>` + + +.. _v2.2.1_infrastructure_InfrastructureLayer: + +InfrastructureLayer +""""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``nodes`` → ComputingNode [0..*] + * ``generators`` → ComputingNodeGenerator [0..*] + * ``storages`` → Storage [0..*] + * ``faas`` → FunctionAsAService [0..*] + * ``credentials`` → Credentials [0..*] + * ``groups`` → ComputingGroup [0..*] + * ``securityGroups`` → SecurityGroup [0..*] + * ``networks`` → Network [0..*] + * ``rules`` → MonitoringRule [0..*] + +.. _v2.2.1_infrastructure_InternetGateway: + +InternetGateway +""""""""""""""" +*Inherits from* :ref:`NetworkInterface <v2.2.1_infrastructure_NetworkInterface>` + +* Attributes: + * ``address`` [String] + +.. _v2.2.1_infrastructure_Location: + +Location +"""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Attributes: + * ``region`` [String] + * ``zone`` [String] + +.. _v2.2.1_infrastructure_MonitoringRule: + +MonitoringRule +"""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Attributes: + * ``condition`` [String] + * ``strategy`` [String] + * ``strategyConfigurationString`` [String] + +.. _v2.2.1_infrastructure_Network: + +Network +""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``connectedIfaces`` → NetworkInterface [0..*] + * ``gateways`` → InternetGateway [0..*] + * ``subnets`` → Subnet [0..*] +* Attributes: + * ``protocol`` [String] + * ``addressRange`` [String] + * ``cidr`` [Integer] + +.. _v2.2.1_infrastructure_NetworkInterface: + +NetworkInterface +"""""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.2.1_infrastructure_InfrastructureElement>` + +* Associations: + * ``belongsTo`` → Network [0..1] + * ``associated`` → SecurityGroup [0..1] +* Attributes: + * ``endPoint`` [Integer] + * ``speed`` [String] + +.. _v2.2.1_infrastructure_PhysicalComputingNode: + +PhysicalComputingNode +""""""""""""""""""""" +*Inherits from* :ref:`ComputingNode <v2.2.1_infrastructure_ComputingNode>` + + +.. _v2.2.1_infrastructure_Rule: + +Rule +"""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Attributes: + * ``kind`` [String] + * ``protocol`` [String] + * ``fromPort`` [Integer] + * ``toPort`` [Integer] + * ``cidr`` [String] + +.. _v2.2.1_infrastructure_SecurityGroup: + +SecurityGroup +""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``rules`` → Rule [0..*] + * ``ifaces`` → NetworkInterface [0..*] + +.. _v2.2.1_infrastructure_Storage: + +Storage +""""""" +*Inherits from* :ref:`InfrastructureElement <v2.2.1_infrastructure_InfrastructureElement>` + +* Associations: + * ``ifaces`` → NetworkInterface [0..*] +* Attributes: + * ``label`` [String] + * ``size_gb`` [Integer] + * ``cost`` [Integer] + +.. _v2.2.1_infrastructure_Subnet: + +Subnet +"""""" +*Inherits from* :ref:`Network <v2.2.1_infrastructure_Network>` + +* Associations: + * ``connectedTo`` → Network [0..*] + +.. _v2.2.1_infrastructure_Swarm: + +Swarm +""""" +*Inherits from* :ref:`ComputingGroup <v2.2.1_infrastructure_ComputingGroup>` + +* Associations: + * ``roles`` → SwarmRole [0..*] + +.. _v2.2.1_infrastructure_SwarmRole: + +SwarmRole +""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``nodes`` → ComputingNode [0..*] +* Attributes: + * ``kind`` [String] + +.. _v2.2.1_infrastructure_VMImage: + +VMImage +""""""" +*Inherits from* :ref:`ComputingNodeGenerator <v2.2.1_infrastructure_ComputingNodeGenerator>` + +* Associations: + * ``generatedVMs`` → VirtualMachine [0..*] + +.. _v2.2.1_infrastructure_VirtualMachine: + +VirtualMachine +"""""""""""""" +*Inherits from* :ref:`ComputingNode <v2.2.1_infrastructure_ComputingNode>` + +* Associations: + * ``generatedFrom`` → VMImage [0..1] +* Attributes: + * ``sizeDescription`` [String] + +concrete +^^^^^^^^ + +.. _v2.2.1_concrete_ComputingGroup: + +ComputingGroup +"""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → ComputingGroup [1..1] + +.. _v2.2.1_concrete_ConcreteElement: + +ConcreteElement +""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``refs`` → ConcreteElement [0..*] +* Attributes: + * ``configurationScript`` [String] + * ``preexisting`` [Boolean] + +.. _v2.2.1_concrete_ConcreteInfrastructure: + +ConcreteInfrastructure +"""""""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``providers`` → RuntimeProvider [0..*] + +.. _v2.2.1_concrete_ContainerImage: + +ContainerImage +"""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → ContainerImage [0..1] + +.. _v2.2.1_concrete_FunctionAsAService: + +FunctionAsAService +"""""""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → FunctionAsAService [0..1] + +.. _v2.2.1_concrete_GenericResource: + +GenericResource +""""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Attributes: + * ``type`` [String] + * ``gname`` [String] + +.. _v2.2.1_concrete_Network: + +Network +""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → Network [0..1] + +.. _v2.2.1_concrete_RuntimeProvider: + +RuntimeProvider +""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.2.1_commons_DOMLElement>` + +* Associations: + * ``resources`` → GenericResource [0..*] + * ``vms`` → VirtualMachine [0..*] + * ``vmImages`` → VMImage [0..*] + * ``containerImages`` → ContainerImage [0..*] + * ``networks`` → Network [0..*] + * ``storages`` → Storage [0..*] + * ``faas`` → FunctionAsAService [0..*] + * ``group`` → ComputingGroup [0..*] + +.. _v2.2.1_concrete_Storage: + +Storage +""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → Storage [0..1] + +.. _v2.2.1_concrete_VMImage: + +VMImage +""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → VMImage [0..1] + +.. _v2.2.1_concrete_VirtualMachine: + +VirtualMachine +"""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.2.1_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → VirtualMachine [0..1] + + + diff --git a/docs/reference_v2.2.rst b/docs/reference_v2.2.rst index eaabad172b58a902520bfad2c82cb3b6026ada48..8fd6ec64526f4792d54f5572a2b670d8afd3122f 100644 --- a/docs/reference_v2.2.rst +++ b/docs/reference_v2.2.rst @@ -120,7 +120,7 @@ UserPass *Inherits from* :ref:`Credentials <v2.2_commons_Credentials>` * Attributes: - * ``user`` [String] + * ``username`` [String] * ``password`` [String] application @@ -427,7 +427,7 @@ Subnet *Inherits from* :ref:`Network <v2.2_infrastructure_Network>` * Associations: - * ``connectedTo`` → Network [0..1] + * ``connectedTo`` → Network [0..*] .. _v2.2_infrastructure_Swarm: diff --git a/docs/reference_v2.3.rst b/docs/reference_v2.3.rst new file mode 100644 index 0000000000000000000000000000000000000000..bf2031e2447840584c72ed2a4ebe30c73bf740b3 --- /dev/null +++ b/docs/reference_v2.3.rst @@ -0,0 +1,594 @@ +DOML v2.3 Reference +============================= + + +commons +^^^^^^^ + +.. _v2.3_commons_BProperty: + +BProperty +""""""""" +*Inherits from* :ref:`Property <v2.3_commons_Property>` + +* Attributes: + * ``value`` [Boolean] + +.. _v2.3_commons_Configuration: + +Configuration +""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``deployments`` → Deployment [0..*] + +.. _v2.3_commons_Credentials: + +Credentials +""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + + +.. _v2.3_commons_DOMLElement: + +DOMLElement +""""""""""" +* Associations: + * ``annotations`` → Property [0..*] +* Attributes: + * ``name`` [String] + * ``description`` [String] + +.. _v2.3_commons_DeployableElement: + +DeployableElement +""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + + +.. _v2.3_commons_Deployment: + +Deployment +"""""""""" +* Associations: + * ``component`` → DeployableElement [1..1] + * ``node`` → InfrastructureElement [1..1] + +.. _v2.3_commons_FProperty: + +FProperty +""""""""" +*Inherits from* :ref:`Property <v2.3_commons_Property>` + +* Attributes: + * ``value`` [String] + +.. _v2.3_commons_IProperty: + +IProperty +""""""""" +*Inherits from* :ref:`Property <v2.3_commons_Property>` + +* Attributes: + * ``value`` [Integer] + +.. _v2.3_commons_KeyPair: + +KeyPair +""""""" +*Inherits from* :ref:`Credentials <v2.3_commons_Credentials>` + +* Attributes: + * ``user`` [String] + * ``keyfile`` [String] + * ``algorithm`` [String] + * ``bits`` [Integer] + +.. _v2.3_commons_Property: + +Property +"""""""" +* Associations: + * ``reference`` → DOMLElement [0..1] +* Attributes: + * ``key`` [String] + +.. _v2.3_commons_SProperty: + +SProperty +""""""""" +*Inherits from* :ref:`Property <v2.3_commons_Property>` + +* Attributes: + * ``value`` [String] + +.. _v2.3_commons_Source: + +Source +"""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Attributes: + * ``entry`` [String] + * ``backend`` [String] + +.. _v2.3_commons_UserPass: + +UserPass +"""""""" +*Inherits from* :ref:`Credentials <v2.3_commons_Credentials>` + +* Attributes: + * ``username`` [String] + * ``password`` [String] + +application +^^^^^^^^^^^ + +.. _v2.3_application_ApplicationComponent: + +ApplicationComponent +"""""""""""""""""""" +*Inherits from* :ref:`DeployableElement <v2.3_commons_DeployableElement>` + + +.. _v2.3_application_ApplicationLayer: + +ApplicationLayer +"""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``components`` → ApplicationComponent [0..*] + +.. _v2.3_application_DBMS: + +DBMS +"""" +*Inherits from* :ref:`SoftwareComponent <v2.3_application_SoftwareComponent>` + + +.. _v2.3_application_SaaS: + +SaaS +"""" +*Inherits from* :ref:`ApplicationComponent <v2.3_application_ApplicationComponent>` + +* Associations: + * ``exposedInterfaces`` → SoftwareInterface [0..*] +* Attributes: + * ``licenseCost`` [String] + +.. _v2.3_application_SaaSDBMS: + +SaaSDBMS +"""""""" +*Inherits from* :ref:`SaaS <v2.3_application_SaaS>` + + +.. _v2.3_application_SoftwareComponent: + +SoftwareComponent +""""""""""""""""" +*Inherits from* :ref:`ApplicationComponent <v2.3_application_ApplicationComponent>` + +* Associations: + * ``exposedInterfaces`` → SoftwareInterface [0..*] + * ``consumedInterfaces`` → SoftwareInterface [0..*] + * ``src`` → Source [0..1] +* Attributes: + * ``isPersistent`` [Boolean] + * ``licenseCost`` [String] + +.. _v2.3_application_SoftwareInterface: + +SoftwareInterface +""""""""""""""""" +*Inherits from* :ref:`ApplicationComponent <v2.3_application_ApplicationComponent>` + +* Attributes: + * ``endPoint`` [String] + +infrastructure +^^^^^^^^^^^^^^ + +.. _v2.3_infrastructure_AutoScalingGroup: + +AutoScalingGroup +"""""""""""""""" +*Inherits from* :ref:`ComputingGroup <v2.3_infrastructure_ComputingGroup>` + +* Associations: + * ``machineDefinition`` → VirtualMachine [1..1] + * ``securityGroup`` → SecurityGroup [0..1] +* Attributes: + * ``min`` [Integer] + * ``max`` [Integer] + * ``loadBalancer`` [String] + +.. _v2.3_infrastructure_ComputingGroup: + +ComputingGroup +"""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``groupedNodes`` → ComputingNode [0..*] + +.. _v2.3_infrastructure_ComputingNode: + +ComputingNode +""""""""""""" +*Inherits from* :ref:`Node <v2.3_infrastructure_Node>` + +* Associations: + * ``location`` → Location [0..1] + * ``credentials`` → Credentials [0..1] + * ``group`` → ComputingGroup [0..1] +* Attributes: + * ``architecture`` [String] + * ``os`` [String] + * ``memory_mb`` [Integer] + * ``memory_kb`` [Integer] + * ``storage`` [String] + * ``cpu_count`` [Integer] + * ``cost`` [Integer] + * ``disabledMonitorings`` [String] + +.. _v2.3_infrastructure_ComputingNodeGenerator: + +ComputingNodeGenerator +"""""""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Attributes: + * ``uri`` [String] + * ``kind`` [GeneratorKind] + +.. _v2.3_infrastructure_Container: + +Container +""""""""" +*Inherits from* :ref:`ComputingNode <v2.3_infrastructure_ComputingNode>` + +* Associations: + * ``generatedFrom`` → ContainerImage [0..1] + * ``configs`` → ContainerConfig [0..*] + +.. _v2.3_infrastructure_ContainerConfig: + +ContainerConfig +""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``host`` → ComputingNode [0..1] + * ``iface`` → NetworkInterface [0..1] +* Attributes: + * ``container_port`` [Integer] + * ``vm_port`` [Integer] + +.. _v2.3_infrastructure_ContainerImage: + +ContainerImage +"""""""""""""" +*Inherits from* :ref:`ComputingNodeGenerator <v2.3_infrastructure_ComputingNodeGenerator>` + +* Associations: + * ``generatedContainers`` → Container [0..*] + +.. _v2.3_infrastructure_ExtInfrastructureElement: + +ExtInfrastructureElement +"""""""""""""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.3_infrastructure_InfrastructureElement>` + + +.. _v2.3_infrastructure_FunctionAsAService: + +FunctionAsAService +"""""""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.3_infrastructure_InfrastructureElement>` + +* Attributes: + * ``cost`` [Integer] + +.. _v2.3_infrastructure_InfrastructureElement: + +InfrastructureElement +""""""""""""""""""""" +*Inherits from* :ref:`DeployableElement <v2.3_commons_DeployableElement>` + + +.. _v2.3_infrastructure_InfrastructureLayer: + +InfrastructureLayer +""""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``nodes`` → ComputingNode [0..*] + * ``generators`` → ComputingNodeGenerator [0..*] + * ``storages`` → Storage [0..*] + * ``faas`` → FunctionAsAService [0..*] + * ``credentials`` → Credentials [0..*] + * ``groups`` → ComputingGroup [0..*] + * ``securityGroups`` → SecurityGroup [0..*] + * ``networks`` → Network [0..*] + * ``rules`` → MonitoringRule [0..*] + +.. _v2.3_infrastructure_InternetGateway: + +InternetGateway +""""""""""""""" +*Inherits from* :ref:`Node <v2.3_infrastructure_Node>` + +* Attributes: + * ``address`` [String] + +.. _v2.3_infrastructure_Location: + +Location +"""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Attributes: + * ``region`` [String] + * ``zone`` [String] + +.. _v2.3_infrastructure_MonitoringRule: + +MonitoringRule +"""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Attributes: + * ``condition`` [String] + * ``strategy`` [String] + * ``strategyConfigurationString`` [String] + +.. _v2.3_infrastructure_Network: + +Network +""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``connectedIfaces`` → NetworkInterface [0..*] + * ``gateways`` → InternetGateway [0..*] + * ``subnets`` → Subnet [0..*] +* Attributes: + * ``protocol`` [String] + * ``addressRange`` [String] + * ``cidr`` [Integer] + +.. _v2.3_infrastructure_NetworkInterface: + +NetworkInterface +"""""""""""""""" +*Inherits from* :ref:`InfrastructureElement <v2.3_infrastructure_InfrastructureElement>` + +* Associations: + * ``belongsTo`` → Network [0..1] + * ``associated`` → SecurityGroup [0..1] +* Attributes: + * ``endPoint`` [Integer] + * ``speed`` [String] + +.. _v2.3_infrastructure_Node: + +Node +"""" +*Inherits from* :ref:`InfrastructureElement <v2.3_infrastructure_InfrastructureElement>` + +* Associations: + * ``ifaces`` → NetworkInterface [0..*] + +.. _v2.3_infrastructure_PhysicalComputingNode: + +PhysicalComputingNode +""""""""""""""""""""" +*Inherits from* :ref:`ComputingNode <v2.3_infrastructure_ComputingNode>` + + +.. _v2.3_infrastructure_Rule: + +Rule +"""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Attributes: + * ``kind`` [String] + * ``protocol`` [String] + * ``fromPort`` [Integer] + * ``toPort`` [Integer] + * ``cidr`` [String] + +.. _v2.3_infrastructure_SecurityGroup: + +SecurityGroup +""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``rules`` → Rule [0..*] + * ``ifaces`` → NetworkInterface [0..*] + +.. _v2.3_infrastructure_Storage: + +Storage +""""""" +*Inherits from* :ref:`Node <v2.3_infrastructure_Node>` + +* Attributes: + * ``label`` [String] + * ``size_gb`` [Integer] + * ``cost`` [Integer] + +.. _v2.3_infrastructure_Subnet: + +Subnet +"""""" +*Inherits from* :ref:`Network <v2.3_infrastructure_Network>` + +* Associations: + * ``connectedTo`` → Network [0..*] + +.. _v2.3_infrastructure_Swarm: + +Swarm +""""" +*Inherits from* :ref:`ComputingGroup <v2.3_infrastructure_ComputingGroup>` + +* Associations: + * ``roles`` → SwarmRole [0..*] + +.. _v2.3_infrastructure_SwarmRole: + +SwarmRole +""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``nodes`` → ComputingNode [0..*] +* Attributes: + * ``kind`` [String] + +.. _v2.3_infrastructure_VMImage: + +VMImage +""""""" +*Inherits from* :ref:`ComputingNodeGenerator <v2.3_infrastructure_ComputingNodeGenerator>` + +* Associations: + * ``generatedVMs`` → VirtualMachine [0..*] + +.. _v2.3_infrastructure_VirtualMachine: + +VirtualMachine +"""""""""""""" +*Inherits from* :ref:`ComputingNode <v2.3_infrastructure_ComputingNode>` + +* Associations: + * ``generatedFrom`` → VMImage [0..1] +* Attributes: + * ``sizeDescription`` [String] + +concrete +^^^^^^^^ + +.. _v2.3_concrete_ComputingGroup: + +ComputingGroup +"""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → ComputingGroup [1..1] + +.. _v2.3_concrete_ConcreteElement: + +ConcreteElement +""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``refs`` → ConcreteElement [0..*] +* Attributes: + * ``configurationScript`` [String] + * ``preexisting`` [Boolean] + +.. _v2.3_concrete_ConcreteInfrastructure: + +ConcreteInfrastructure +"""""""""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``providers`` → RuntimeProvider [0..*] + +.. _v2.3_concrete_ContainerImage: + +ContainerImage +"""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → ContainerImage [0..1] + +.. _v2.3_concrete_FunctionAsAService: + +FunctionAsAService +"""""""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → FunctionAsAService [0..1] + +.. _v2.3_concrete_GenericResource: + +GenericResource +""""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Attributes: + * ``type`` [String] + * ``gname`` [String] + +.. _v2.3_concrete_Network: + +Network +""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → Network [0..1] + +.. _v2.3_concrete_RuntimeProvider: + +RuntimeProvider +""""""""""""""" +*Inherits from* :ref:`DOMLElement <v2.3_commons_DOMLElement>` + +* Associations: + * ``resources`` → GenericResource [0..*] + * ``vms`` → VirtualMachine [0..*] + * ``vmImages`` → VMImage [0..*] + * ``containerImages`` → ContainerImage [0..*] + * ``networks`` → Network [0..*] + * ``storages`` → Storage [0..*] + * ``faas`` → FunctionAsAService [0..*] + * ``group`` → ComputingGroup [0..*] + +.. _v2.3_concrete_Storage: + +Storage +""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → Storage [0..1] + +.. _v2.3_concrete_VMImage: + +VMImage +""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → VMImage [0..1] +* Attributes: + * ``image_name`` [String] + +.. _v2.3_concrete_VirtualMachine: + +VirtualMachine +"""""""""""""" +*Inherits from* :ref:`ConcreteElement <v2.3_concrete_ConcreteElement>` + +* Associations: + * ``maps`` → VirtualMachine [0..1] + + + diff --git a/mc_openapi/assets/doml_meta_v2.3.yaml b/mc_openapi/assets/doml_meta_v2.3.yaml new file mode 100644 index 0000000000000000000000000000000000000000..cda67949f57f16186ebf590c630783eefcf60316 --- /dev/null +++ b/mc_openapi/assets/doml_meta_v2.3.yaml @@ -0,0 +1,551 @@ +commons: + DOMLElement: + attributes: + name: + type: String + multiplicity: "0..1" + description: + type: String + multiplicity: "0..1" + associations: + annotations: + class: commons_Property + multiplicity: "0..*" + Property: + attributes: + key: + type: String + multiplicity: "0..1" + associations: + reference: + class: commons_DOMLElement + multiplicity: "0..1" + IProperty: + superclass: commons_Property + attributes: + value: + type: Integer + multiplicity: "0..1" + SProperty: + superclass: commons_Property + attributes: + value: + type: String + multiplicity: "0..1" + FProperty: + superclass: commons_Property + attributes: + value: + type: String + multiplicity: "0..1" + BProperty: + superclass: commons_Property + attributes: + value: + type: Boolean + multiplicity: "0..1" + Configuration: + superclass: commons_DOMLElement + associations: + deployments: + class: commons_Deployment + multiplicity: "0..*" + Credentials: + abstract: true + superclass: commons_DOMLElement + DeployableElement: + abstract: true + superclass: commons_DOMLElement # It's not present in the ECore, but without it breaks. + Deployment: + associations: + component: + class: commons_DeployableElement + multiplicity: "1" + node: + class: infrastructure_InfrastructureElement + multiplicity: "1" + KeyPair: + superclass: commons_Credentials + attributes: + user: + type: String + multiplicity: "0..1" + keyfile: + type: String + multiplicity: "0..1" + algorithm: + type: String + multiplicity: "0..1" + bits: + type: Integer + multiplicity: "0..1" + UserPass: + superclass: commons_Credentials + attributes: + username: + type: String + multiplicity: "0..1" + password: + type: String + multiplicity: "0..1" + Source: + superclass: commons_DOMLElement + attributes: + entry: + type: String + multiplicity: "0..*" + backend: + type: String + multiplicity: "0..*" +application: + ApplicationLayer: + superclass: commons_DOMLElement + associations: + components: + class: application_ApplicationComponent + multiplicity: "0..*" + ApplicationComponent: + superclass: commons_DeployableElement # and commons_DOMLElement too, but that's definitely wrong; keeping discarding DOMLElement since DeplElem inherits it. + SoftwareComponent: + superclass: application_ApplicationComponent + attributes: + isPersistent: + type: Boolean + multiplicity: "1" + default: false + licenseCost: + type: String + multiplicity: "0..1" + associations: + exposedInterfaces: + class: application_SoftwareInterface + multiplicity: "0..*" + consumedInterfaces: + class: application_SoftwareInterface + multiplicity: "0..*" + src: + class: commons_Source + multiplicity: "0..1" + SaaS: + superclass: application_ApplicationComponent + attributes: + licenseCost: + type: String + multiplicity: "0..1" + associations: + exposedInterfaces: + class: application_SoftwareInterface + multiplicity: "0..*" + SoftwareInterface: + superclass: application_ApplicationComponent + attributes: + endPoint: + type: String + multiplicity: "0..1" + DBMS: + superclass: application_SoftwareComponent + SaaSDBMS: + superclass: application_SaaS + +infrastructure: + InfrastructureLayer: + superclass: commons_DOMLElement + associations: + nodes: + class: infrastructure_ComputingNode + multiplicity: "0..*" + generators: + class: infrastructure_ComputingNodeGenerator + multiplicity: "0..*" + storages: + class: infrastructure_Storage + multiplicity: "0..*" + faas: + class: infrastructure_FunctionAsAService + multiplicity: "0..*" + credentials: + class: commons_Credentials + multiplicity: "0..*" + groups: + class: infrastructure_ComputingGroup + multiplicity: "0..*" + securityGroups: + class: infrastructure_SecurityGroup + multiplicity: "0..*" + networks: + class: infrastructure_Network + multiplicity: "0..*" + rules: + class: infrastructure_MonitoringRule + multiplicity: "0..*" + MonitoringRule: + superclass: commons_DOMLElement + attributes: + condition: + type: String + multiplicity: "1" + strategy: + type: String + multiplicity: "1" + strategyConfigurationString: + type: String + multiplicity: "0..1" + InfrastructureElement: + superclass: commons_DeployableElement + Node: + superclass: infrastructure_InfrastructureElement + associations: + ifaces: + class: infrastructure_NetworkInterface + multiplicity: "0..*" + ComputingNode: + superclass: infrastructure_Node + attributes: + architecture: + type: String + multiplicity: "0..1" + os: + type: String + multiplicity: "0..1" + memory_mb: + type: Integer + multiplicity: "0..1" + memory_kb: # Missing in official Ecore, added by parser + type: Integer + multiplicity: "0..1" + storage: + type: String + multiplicity: "0..1" + cpu_count: + type: Integer + multiplicity: "0..1" + cost: + type: Integer # in cents + multiplicity: "0..1" + disabledMonitorings: + type: String + multiplicity: "0..1" + associations: + location: + class: infrastructure_Location + multiplicity: "0..1" + credentials: + class: commons_Credentials + multiplicity: "0..1" + group: + class: infrastructure_ComputingGroup + multiplicity: "0..1" + inverse_of: infrastructure_ComputingGroup::groupedNodes + PhysicalComputingNode: + superclass: infrastructure_ComputingNode + VirtualMachine: + superclass: infrastructure_ComputingNode + attributes: + sizeDescription: + type: String + multiplicity: "0..1" + associations: + generatedFrom: + class: infrastructure_VMImage + multiplicity: "0..1" + Location: + superclass: commons_DOMLElement + attributes: + region: + type: String + multiplicity: "0..1" + zone: + type: String + multiplicity: "0..1" + ContainerConfig: + superclass: commons_DOMLElement + attributes: + container_port: + type: Integer + multiplicity: "0..1" + vm_port: + type: Integer + multiplicity: "0..1" + associations: + host: + class: infrastructure_ComputingNode + multiplicity: "0..1" + iface: + class: infrastructure_NetworkInterface + multiplicity: "0..1" + Container: + superclass: infrastructure_ComputingNode + associations: + generatedFrom: + class: infrastructure_ContainerImage + multiplicity: "0..1" + configs: + class: infrastructure_ContainerConfig + multiplicity: "0..*" + ComputingNodeGenerator: + superclass: commons_DOMLElement + attributes: + uri: + type: String + multiplicity: "0..1" + kind: + type: GeneratorKind # enum { SCRIPT, IMAGE } + VMImage: + superclass: infrastructure_ComputingNodeGenerator + associations: + generatedVMs: + class: infrastructure_VirtualMachine + multiplicity: "0..*" + inverse_of: infrastructure_VirtualMachine::generatedFrom + ContainerImage: + superclass: infrastructure_ComputingNodeGenerator + associations: + generatedContainers: + class: infrastructure_Container + multiplicity: "0..*" + inverse_of: infrastructure_Container::generatedFrom + AutoScalingGroup: + superclass: infrastructure_ComputingGroup + attributes: + min: + type: Integer + multiplicity: "0..1" + max: + type: Integer + multiplicity: "0..1" + loadBalancer: + type: String + multiplicity: "0..1" + associations: + machineDefinition: + class: infrastructure_VirtualMachine + multiplicity: "1" + securityGroup: + class: infrastructure_SecurityGroup + multiplicity: "0..1" + Storage: + superclass: infrastructure_Node + attributes: + label: + type: String + multiplicity: "0..1" + size_gb: + type: Integer # in GBs + multiplicity: "0..1" + cost: + type: Integer # in cents + multiplicity: "0..1" + FunctionAsAService: + superclass: infrastructure_InfrastructureElement + attributes: + cost: + type: Integer # in cents + multiplicity: "0..1" + Network: + superclass: commons_DOMLElement + attributes: + protocol: + type: String + multiplicity: "0..1" + addressRange: + type: String + multiplicity: "0..1" + cidr: + type: Integer + multiplicity: "0..1" + associations: + connectedIfaces: + class: infrastructure_NetworkInterface + multiplicity: "0..*" + inverse_of: infrastructure_NetworkInterface::belongsTo + gateways: + class: infrastructure_InternetGateway + multiplicity: "0..*" + subnets: + class: infrastructure_Subnet + multiplicity: "0..*" + Subnet: + superclass: infrastructure_Network + associations: + connectedTo: + class: infrastructure_Network + multiplicity: "0..*" + NetworkInterface: + superclass: infrastructure_InfrastructureElement + attributes: + endPoint: + type: Integer + multiplicity: "0..1" + speed: + type: String + multiplicity: "0..1" + associations: + belongsTo: + class: infrastructure_Network + multiplicity: "0..1" # This should be "1", but it would break InternetGateway + associated: + class: infrastructure_SecurityGroup + multiplicity: "0..1" + InternetGateway: + superclass: infrastructure_Node + attributes: + address: + type: String + multiplicity: "1" + ComputingGroup: + superclass: commons_DOMLElement + associations: + groupedNodes: + class: infrastructure_ComputingNode + multiplicity: "0..*" + inverse_of: infrastructure_ComputingNode::group + SecurityGroup: + superclass: commons_DOMLElement + associations: + rules: + class: infrastructure_Rule + multiplicity: "0..*" + ifaces: + class: infrastructure_NetworkInterface + multiplicity: "0..*" + inverse_of: infrastructure_NetworkInterface::associated + Rule: + superclass: commons_DOMLElement + attributes: + kind: + type: String + multiplicity: "1" + protocol: + type: String + multiplicity: "1" + fromPort: + type: Integer + multiplicity: "1" + toPort: + type: Integer + multiplicity: "1" + cidr: + type: String + multiplicity: "0..*" + SwarmRole: + superclass: commons_DOMLElement + attributes: + kind: + type: String + multiplicity: "1" + associations: + nodes: + class: infrastructure_ComputingNode + multiplicity: "0..*" + Swarm: + superclass: infrastructure_ComputingGroup + associations: + roles: + class: infrastructure_SwarmRole + multiplicity: "0..*" + ExtInfrastructureElement: + superclass: infrastructure_InfrastructureElement + +concrete: + ConcreteInfrastructure: + superclass: commons_DOMLElement + associations: + providers: + class: concrete_RuntimeProvider + multiplicity: "0..*" + ConcreteElement: + superclass: commons_DOMLElement + associations: + refs: + class: concrete_ConcreteElement + multiplicity: "0..*" + attributes: + configurationScript: + type: String + multiplicity: "0..1" + preexisting: + multiplicity: "1" + type: Boolean + default: false + RuntimeProvider: + superclass: commons_DOMLElement + associations: + resources: + class: concrete_GenericResource + multiplicity: "0..*" + vms: + class: concrete_VirtualMachine + multiplicity: "0..*" + vmImages: + class: concrete_VMImage + multiplicity: "0..*" + containerImages: + class: concrete_ContainerImage + multiplicity: "0..*" + networks: + class: concrete_Network + multiplicity: "0..*" + storages: + class: concrete_Storage + multiplicity: "0..*" + faas: + class: concrete_FunctionAsAService + multiplicity: "0..*" + group: + class: concrete_ComputingGroup + multiplicity: "0..*" + VirtualMachine: + superclass: concrete_ConcreteElement + associations: + maps: + class: infrastructure_VirtualMachine + multiplicity: "0..1" + VMImage: + superclass: concrete_ConcreteElement + attributes: + image_name: + type: String + multiplicity: "1" + associations: + maps: + class: infrastructure_VMImage + multiplicity: "0..1" + ContainerImage: + superclass: concrete_ConcreteElement + associations: + maps: + class: infrastructure_ContainerImage + multiplicity: "0..1" + Network: + superclass: concrete_ConcreteElement + associations: + maps: + class: infrastructure_Network + multiplicity: "0..1" + Storage: + superclass: concrete_ConcreteElement + associations: + maps: + class: infrastructure_Storage + multiplicity: "0..1" + FunctionAsAService: + superclass: concrete_ConcreteElement + associations: + maps: + class: infrastructure_FunctionAsAService + multiplicity: "0..1" + ComputingGroup: + superclass: concrete_ConcreteElement + associations: + maps: + class: infrastructure_ComputingGroup + multiplicity: "1" + GenericResource: + superclass: concrete_ConcreteElement + attributes: + type: + type: "String" + multiplicity: "1" + gname: + type: "String" + multiplicity: "1" diff --git a/mc_openapi/assets/doml_v2.3.ecore b/mc_openapi/assets/doml_v2.3.ecore new file mode 100644 index 0000000000000000000000000000000000000000..30a5244fea7c765953d14e30108c5163936f1758 --- /dev/null +++ b/mc_openapi/assets/doml_v2.3.ecore @@ -0,0 +1,422 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="doml" nsURI="http://www.piacere-project.eu/doml" nsPrefix="doml"> + <eAnnotations source="emf.gen"> + <details key="basePackage" value="eu.piacere.doml"/> + <details key="fileExtensions" value="domlx"/> + <details key="complianceLevel" value="JDK80"/> + </eAnnotations> + <eSubpackages name="commons" nsURI="http://www.piacere-project.eu/doml/commons" + nsPrefix="commons"> + <eClassifiers xsi:type="ecore:EClass" name="DOMLModel" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="version" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString" + defaultValueLiteral="2.2"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="application" eType="#//application/ApplicationLayer" + containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="infrastructure" eType="#//infrastructure/InfrastructureLayer" + containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="concretizations" upperBound="-1" + eType="#//concrete/ConcreteInfrastructure" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="optimization" eType="#//optimization/OptimizationLayer" + containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="configurations" upperBound="-1" + eType="#//commons/Configuration" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="activeConfiguration" + eType="#//commons/Configuration"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="activeInfrastructure" + eType="#//concrete/ConcreteInfrastructure"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="functionalRequirements" + upperBound="-1" eType="#//commons/Requirement" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Property" abstract="true"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="key" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="IProperty" eSuperTypes="#//commons/Property"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="SProperty" eSuperTypes="#//commons/Property"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="FProperty" eSuperTypes="#//commons/Property"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="BProperty" eSuperTypes="#//commons/Property"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBooleanObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ExtensionElement" abstract="true"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="metaclassName" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="DOMLElement" abstract="true"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="description" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="annotations" upperBound="-1" + eType="#//commons/Property" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="contributesTo" upperBound="-1" + eType="#//commons/Requirement" eOpposite="#//commons/Requirement/predicatesOn"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Configuration" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="deployments" upperBound="-1" + eType="#//commons/Deployment" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="DeployableElement" abstract="true"/> + <eClassifiers xsi:type="ecore:EClass" name="Deployment"> + <eStructuralFeatures xsi:type="ecore:EReference" name="component" lowerBound="1" + eType="#//commons/DeployableElement"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="node" lowerBound="1" + eType="#//infrastructure/InfrastructureElement"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Requirement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="description" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="property" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="predicatesOn" upperBound="-1" + eType="#//commons/DOMLElement" eOpposite="#//commons/DOMLElement/contributesTo"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="RangedRequirement" eSuperTypes="#//commons/Requirement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="min" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="max" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="EnumeratedRequirement" eSuperTypes="#//commons/Requirement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="values" upperBound="-1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="DeploymentRequirement" abstract="true" + eSuperTypes="#//commons/Requirement"/> + <eClassifiers xsi:type="ecore:EClass" name="DeploymentToNodeTypeRequirement" eSuperTypes="#//commons/DeploymentRequirement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="validTypes" upperBound="-1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="DeploymentToNodeWithPropertyRequirement" + eSuperTypes="#//commons/DeploymentRequirement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="min" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="max" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="values" upperBound="-1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="DeploymentToSpecificNodeRequirement" + eSuperTypes="#//commons/DeploymentRequirement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="validElements" upperBound="-1" + eType="#//infrastructure/InfrastructureElement"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Credentials" abstract="true" eSuperTypes="#//commons/DOMLElement"/> + <eClassifiers xsi:type="ecore:EClass" name="KeyPair" eSuperTypes="#//commons/Credentials"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="user" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="keyfile" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="algorithm" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="bits" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="UserPass" eSuperTypes="#//commons/Credentials"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="username" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="password" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Source" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="entry" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="backend" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + </eSubpackages> + <eSubpackages name="application" nsURI="http://www.piacere-project.eu/doml/application" + nsPrefix="app"> + <eClassifiers xsi:type="ecore:EClass" name="ApplicationLayer" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="components" upperBound="-1" + eType="#//application/ApplicationComponent" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ApplicationComponent" abstract="true" + eSuperTypes="#//commons/DOMLElement #//commons/DeployableElement"/> + <eClassifiers xsi:type="ecore:EClass" name="SoftwareComponent" eSuperTypes="#//application/ApplicationComponent"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="isPersistent" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBooleanObject" + defaultValueLiteral="false"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="licenseCost" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="exposedInterfaces" upperBound="-1" + eType="#//application/SoftwareInterface" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="consumedInterfaces" upperBound="-1" + eType="#//application/SoftwareInterface"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="src" eType="#//commons/Source" + containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="DBMS" eSuperTypes="#//application/SoftwareComponent"/> + <eClassifiers xsi:type="ecore:EClass" name="SaaS" eSuperTypes="#//application/ApplicationComponent"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="licenseCost" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="exposedInterfaces" upperBound="-1" + eType="#//application/SoftwareInterface" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="SaaSDBMS" eSuperTypes="#//application/SaaS"/> + <eClassifiers xsi:type="ecore:EClass" name="SoftwareInterface" eSuperTypes="#//application/ApplicationComponent"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="endPoint" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ExtApplicationComponent" eSuperTypes="#//application/ApplicationComponent #//commons/ExtensionElement"/> + </eSubpackages> + <eSubpackages name="infrastructure" nsURI="http://www.piacere-project.eu/doml/infrastructure" + nsPrefix="infra"> + <eClassifiers xsi:type="ecore:EClass" name="InfrastructureLayer" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="nodes" upperBound="-1" + eType="#//infrastructure/ComputingNode" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="generators" upperBound="-1" + eType="#//infrastructure/ComputingNodeGenerator" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="storages" upperBound="-1" + eType="#//infrastructure/Storage" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="faas" upperBound="-1" + eType="#//infrastructure/FunctionAsAService" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="credentials" upperBound="-1" + eType="#//commons/Credentials" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="groups" upperBound="-1" + eType="#//infrastructure/ComputingGroup" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="securityGroups" upperBound="-1" + eType="#//infrastructure/SecurityGroup" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="networks" upperBound="-1" + eType="#//infrastructure/Network" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="rules" upperBound="-1" + eType="#//infrastructure/MonitoringRule" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="MonitoringRule" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="condition" lowerBound="1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="strategy" lowerBound="1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="strategyConfigurationString" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ComputingGroup" abstract="true" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="groupedNodes" upperBound="-1" + eType="#//infrastructure/ComputingNode" eOpposite="#//infrastructure/ComputingNode/group"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="AutoScalingGroup" eSuperTypes="#//infrastructure/ComputingGroup"> + <eStructuralFeatures xsi:type="ecore:EReference" name="machineDefinition" lowerBound="1" + eType="#//infrastructure/VirtualMachine" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="min" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject" + defaultValueLiteral="1"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="max" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject" + defaultValueLiteral="1"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="securityGroup" eType="#//infrastructure/SecurityGroup" + containment="true"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="loadBalancer" eType="#//infrastructure/LoadBalancerKind" + defaultValueLiteral="DEFAULT"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EEnum" name="LoadBalancerKind"> + <eLiterals name="DEFAULT"/> + <eLiterals name="INTERNAL" value="1"/> + <eLiterals name="EXTERNAL" value="2"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Rule" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="kind" eType="#//infrastructure/RuleKind"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="protocol" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="fromPort" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="toPort" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="cidr" upperBound="-1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EEnum" name="RuleKind"> + <eLiterals name="EGRESS"/> + <eLiterals name="INGRESS" value="1"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="SecurityGroup" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="rules" upperBound="-1" + eType="#//infrastructure/Rule" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="ifaces" upperBound="-1" + eType="#//infrastructure/NetworkInterface" eOpposite="#//infrastructure/NetworkInterface/associated"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="AvailabilityGroup" eSuperTypes="#//infrastructure/ComputingGroup"/> + <eClassifiers xsi:type="ecore:EClass" name="InfrastructureElement" abstract="true" + eSuperTypes="#//commons/DOMLElement #//commons/DeployableElement"/> + <eClassifiers xsi:type="ecore:EClass" name="Node" abstract="true" eSuperTypes="#//infrastructure/InfrastructureElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="ifaces" upperBound="-1" + eType="#//infrastructure/NetworkInterface" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ComputingNode" abstract="true" eSuperTypes="#//infrastructure/Node"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="architecture" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="os" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="memory_mb" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="storage" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="cpu_count" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="cost" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="location" eType="#//infrastructure/Location" + containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="credentials" eType="#//commons/Credentials"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="group" eType="#//infrastructure/ComputingGroup" + eOpposite="#//infrastructure/ComputingGroup/groupedNodes"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="disabledMonitorings" + upperBound="-1" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ComputingNodeGenerator" abstract="true" + eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="uri" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="kind" eType="#//infrastructure/GeneratorKind"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EEnum" name="GeneratorKind"> + <eLiterals name="SCRIPT"/> + <eLiterals name="IMAGE" value="1"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="VMImage" eSuperTypes="#//infrastructure/ComputingNodeGenerator"> + <eStructuralFeatures xsi:type="ecore:EReference" name="generatedVMs" upperBound="-1" + eType="#//infrastructure/VirtualMachine" eOpposite="#//infrastructure/VirtualMachine/generatedFrom"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ContainerImage" eSuperTypes="#//infrastructure/ComputingNodeGenerator"> + <eStructuralFeatures xsi:type="ecore:EReference" name="generatedContainers" + upperBound="-1" eType="#//infrastructure/Container" eOpposite="#//infrastructure/Container/generatedFrom"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="PhysicalComputingNode" eSuperTypes="#//infrastructure/ComputingNode"/> + <eClassifiers xsi:type="ecore:EClass" name="VirtualMachine" eSuperTypes="#//infrastructure/ComputingNode"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="sizeDescription" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="generatedFrom" eType="#//infrastructure/VMImage" + eOpposite="#//infrastructure/VMImage/generatedVMs"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Location" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="region" lowerBound="1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="zone" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ContainerConfig" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="container_port" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="vm_port" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EIntegerObject"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="host" eType="#//infrastructure/ComputingNode"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="iface" eType="#//infrastructure/NetworkInterface"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Container" eSuperTypes="#//infrastructure/ComputingNode"> + <eStructuralFeatures xsi:type="ecore:EReference" name="generatedFrom" eType="#//infrastructure/ContainerImage" + eOpposite="#//infrastructure/ContainerImage/generatedContainers"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="configs" upperBound="-1" + eType="#//infrastructure/ContainerConfig" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Network" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="protocol" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="addressRange" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="connectedIfaces" upperBound="-1" + eType="#//infrastructure/NetworkInterface" eOpposite="#//infrastructure/NetworkInterface/belongsTo"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="gateways" upperBound="-1" + eType="#//infrastructure/InternetGateway" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="subnets" upperBound="-1" + eType="#//infrastructure/Subnet" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Subnet" eSuperTypes="#//infrastructure/Network"> + <eStructuralFeatures xsi:type="ecore:EReference" name="connectedTo" upperBound="-1" + eType="#//infrastructure/Subnet"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="NetworkInterface" eSuperTypes="#//infrastructure/InfrastructureElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="speed" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="endPoint" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="belongsTo" eType="#//infrastructure/Network" + eOpposite="#//infrastructure/Network/connectedIfaces"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="associated" upperBound="-1" + eType="#//infrastructure/SecurityGroup" eOpposite="#//infrastructure/SecurityGroup/ifaces"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="InternetGateway" eSuperTypes="#//infrastructure/Node"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="address" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Storage" eSuperTypes="#//infrastructure/InfrastructureElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="label" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="size_gb" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EInt"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="cost" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="FunctionAsAService" eSuperTypes="#//infrastructure/InfrastructureElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="cost" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EEnum" name="RoleKind"> + <eLiterals name="NONE"/> + <eLiterals name="MANAGER" value="1"/> + <eLiterals name="WORKER" value="2"/> + <eLiterals name="MASTER" value="3"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="SwarmRole" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="kind" eType="#//infrastructure/RoleKind"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="nodes" upperBound="-1" + eType="#//infrastructure/ComputingNode" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Swarm" eSuperTypes="#//infrastructure/ComputingGroup"> + <eStructuralFeatures xsi:type="ecore:EReference" name="roles" upperBound="-1" + eType="#//infrastructure/SwarmRole" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ExtInfrastructureElement" eSuperTypes="#//infrastructure/InfrastructureElement #//commons/ExtensionElement"/> + </eSubpackages> + <eSubpackages name="concrete" nsURI="http://www.piacere-project.eu/doml/concrete" + nsPrefix="concrete"> + <eClassifiers xsi:type="ecore:EClass" name="ConcreteInfrastructure" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="providers" upperBound="-1" + eType="#//concrete/RuntimeProvider" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="RuntimeProvider" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="resources" upperBound="-1" + eType="#//concrete/GenericResource" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="vms" upperBound="-1" + eType="#//concrete/VirtualMachine" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="vmImages" upperBound="-1" + eType="#//concrete/VMImage" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="containerImages" upperBound="-1" + eType="#//concrete/ContainerImage" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="networks" upperBound="-1" + eType="#//concrete/Network" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="storages" upperBound="-1" + eType="#//concrete/Storage" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="faas" upperBound="-1" + eType="#//concrete/FunctionAsAService" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="group" upperBound="-1" + eType="#//concrete/ComputingGroup" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ConcreteElement" abstract="true" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="configurationScript" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="preexisting" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBooleanObject" + defaultValueLiteral="false"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="refs" upperBound="-1" + eType="#//concrete/ConcreteElement"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="GenericResource" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="type" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="gname" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="VirtualMachine" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/VirtualMachine"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="VMImage" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="image_name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/VMImage"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ContainerImage" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/ContainerImage"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Network" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/Network"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Storage" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/Storage"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="FunctionAsAService" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/FunctionAsAService"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ComputingGroup" eSuperTypes="#//concrete/ConcreteElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="maps" eType="#//infrastructure/ComputingGroup"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ExtConcreteElement" eSuperTypes="#//concrete/ConcreteElement #//commons/ExtensionElement"/> + </eSubpackages> + <eSubpackages name="optimization" nsURI="http://www.piacere-project.eu/doml/optimization" + nsPrefix="optimization"> + <eClassifiers xsi:type="ecore:EClass" name="OptimizationLayer" eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="startingHint" eType="#//commons/Configuration"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="solutions" upperBound="-1" + eType="#//optimization/OptimizationSolution" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="objectives" upperBound="-1" + eType="#//optimization/OptimizationObjective" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="nonfunctionalRequirements" + upperBound="-1" eType="#//commons/Requirement" containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="ObjectiveValue"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="cost" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="availability" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="performance" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EFloatObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="OptimizationSolution" eSuperTypes="#//commons/Configuration"> + <eStructuralFeatures xsi:type="ecore:EReference" name="objectives" eType="#//optimization/ObjectiveValue" + containment="true"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="decisions" upperBound="-1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="OptimizationObjective" abstract="true" + eSuperTypes="#//commons/DOMLElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="kind" lowerBound="1" + eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString" + defaultValueLiteral="Max"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="property" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="CountObjective" eSuperTypes="#//optimization/OptimizationObjective"/> + <eClassifiers xsi:type="ecore:EClass" name="MeasurableObjective" eSuperTypes="#//optimization/OptimizationObjective"/> + <eClassifiers xsi:type="ecore:EClass" name="ExtOptimizationObjective" eSuperTypes="#//optimization/OptimizationObjective #//commons/ExtensionElement"/> + </eSubpackages> +</ecore:EPackage> diff --git a/mc_openapi/doml_mc/common_reqs.py b/mc_openapi/doml_mc/common_reqs.py index 23e4ac3298e0fb41e96e27d036c6ca1c63648d0a..033111e9688c3d678f64439412aec2f0d9831439 100644 --- a/mc_openapi/doml_mc/common_reqs.py +++ b/mc_openapi/doml_mc/common_reqs.py @@ -28,6 +28,20 @@ def vm_iface(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprRef: ) ) +def vm_iface_v2_3(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprRef: + vm, iface = get_consts(smtsorts, ["vm", "iface"]) + return And( + smtenc.element_class_fun( + vm) == smtenc.classes["infrastructure_VirtualMachine"], + Not( + Exists( + [iface], + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], iface) + ) + ) + ) + # All software packages can see the interfaces they need through a common network. @@ -363,6 +377,171 @@ def software_package_iface_net_v2_1(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ) ) +def software_package_iface_net_v2_3(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprRef: + asc_consumer, asc_exposer, siface, net, net_iface, cnode, cdeployment, enode, edeployment, vm, cconf, csubnet, esubnet = get_consts( + smtsorts, + ["asc_consumer", "asc_exposer", "siface", "net", "net_iface", + "cnode", "cdeployment", "enode", "edeployment", "vm", "cconf", "csubnet", "esubnet"] + ) + return And( + smtenc.association_rel( + asc_consumer, smtenc.associations["application_SoftwareComponent::exposedInterfaces"], siface), + smtenc.association_rel( + asc_exposer, smtenc.associations["application_SoftwareComponent::consumedInterfaces"], siface), + Not( + Or( + Exists( + [cdeployment, cnode, edeployment, enode, net], + And( + smtenc.association_rel( + cdeployment, smtenc.associations["commons_Deployment::component"], asc_consumer), + smtenc.association_rel( + cdeployment, smtenc.associations["commons_Deployment::node"], cnode), + Exists( + [vm, net_iface, cconf], + Or( + And( # asc_consumer is deployed on a component with an interface in network n + smtenc.association_rel( + cnode, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], net), + ), + And( # asc_consumer is deployed on a container hosted in a VM with an interface in network n + smtenc.association_rel( + cnode, smtenc.associations["infrastructure_Container::configs"], cconf), + smtenc.association_rel( + cconf, smtenc.associations["infrastructure_ContainerConfig::host"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], net), + ), + And( # asc_consumer is deployed on a VM in an AutoScalingGroup with an interface in network n + smtenc.association_rel( + cnode, smtenc.associations["infrastructure_AutoScalingGroup::machineDefinition"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], net), + ), + ) + ), + smtenc.association_rel( + edeployment, smtenc.associations["commons_Deployment::component"], asc_exposer), + smtenc.association_rel( + edeployment, smtenc.associations["commons_Deployment::node"], enode), + Exists( + [vm, net_iface, cconf], + Or( + And( # asc_exposer is deployed on a component with an interface in network n + smtenc.association_rel( + enode, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], net), + ), + And( # asc_exposer is deployed on a container hosted on a VM with an interface in network n + smtenc.association_rel( + enode, smtenc.associations["infrastructure_Container::configs"], cconf), + smtenc.association_rel( + cconf, smtenc.associations["infrastructure_ContainerConfig::host"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], net), + ), + And( # asc_exposer is deployed on a VM in an AutoScalingGroup with an interface in network n + smtenc.association_rel( + enode, smtenc.associations["infrastructure_AutoScalingGroup::machineDefinition"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], net), + ), + ) + ) + ) + ), # OR + Exists( + [cdeployment, cnode, edeployment, enode, csubnet, esubnet], + And( + smtenc.association_rel( + cdeployment, smtenc.associations["commons_Deployment::component"], asc_consumer), + smtenc.association_rel( + cdeployment, smtenc.associations["commons_Deployment::node"], cnode), + Or( + smtenc.association_rel( + csubnet, smtenc.associations["infrastructure_Subnet::connectedTo"], esubnet), + smtenc.association_rel( + esubnet, smtenc.associations["infrastructure_Subnet::connectedTo"], csubnet), + ), + Exists( + [vm, net_iface, cconf], + Or( + And( # asc_consumer is deployed on a component with an interface in network n + smtenc.association_rel( + cnode, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], csubnet), + ), + And( # asc_consumer is deployed on a container hosted in a VM with an interface in network n + smtenc.association_rel( + cnode, smtenc.associations["infrastructure_Container::configs"], cconf), + smtenc.association_rel( + cconf, smtenc.associations["infrastructure_ContainerConfig::host"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], csubnet), + ), + And( # asc_consumer is deployed on a VM in an AutoScalingGroup with an interface in network n + smtenc.association_rel( + cnode, smtenc.associations["infrastructure_AutoScalingGroup::machineDefinition"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], csubnet), + ), + ) + ), + smtenc.association_rel( + edeployment, smtenc.associations["commons_Deployment::component"], asc_exposer), + smtenc.association_rel( + edeployment, smtenc.associations["commons_Deployment::node"], enode), + Exists( + [vm, net_iface, cconf], + Or( + And( # asc_exposer is deployed on a component with an interface in network n + smtenc.association_rel( + enode, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], esubnet), + ), + And( # asc_exposer is deployed on a container hosted on a VM with an interface in network n + smtenc.association_rel( + enode, smtenc.associations["infrastructure_Container::configs"], cconf), + smtenc.association_rel( + cconf, smtenc.associations["infrastructure_ContainerConfig::host"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], esubnet), + ), + And( # asc_exposer is deployed on a VM in an AutoScalingGroup with an interface in network n + smtenc.association_rel( + enode, smtenc.associations["infrastructure_AutoScalingGroup::machineDefinition"], vm), + smtenc.association_rel( + vm, smtenc.associations["infrastructure_Node::ifaces"], net_iface), + smtenc.association_rel( + net_iface, smtenc.associations["infrastructure_NetworkInterface::belongsTo"], esubnet), + ) + ) + ) + ) + ) + ) + ) + ) + # There are no duplicated interfaces. def iface_uniq(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprRef: @@ -497,7 +676,10 @@ def all_concrete_map_something(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprR # ) # ) - +# From DOML V2.3+: +# The association between security groups and network interfaces can now be done only +# in the security groups definition through the “ifaces” keyword (removed the "security" +# keyword in the network interface definition) def security_group_must_have_iface(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprRef: sg, iface = get_consts(smtsorts, ["sg iface"]) return And( @@ -510,8 +692,7 @@ def security_group_must_have_iface(smtenc: SMTEncoding, smtsorts: SMTSorts) -> E ) # TODO: Check if HTTP should be disabled too - - +# TODO: Add support for DOML 2.3+ if kept def external_services_must_have_https(smtenc: SMTEncoding, smtsorts: SMTSorts) -> ExprRef: saas, sw_iface, sw_comp, deployment, ielem, net_iface, sec_group, rule = get_consts(smtsorts, ["saas, sw_iface, sw_comp, deployment, ielem, net_iface, sec_group, rule"]) @@ -656,14 +837,6 @@ def ed_external_services_must_have_https(solver: Solver, smtsorts: SMTSorts, int RequirementLists = { - # DOMLVersion.V1_0: [ - # (vm_iface, "vm_iface", "All virtual machines must be connected to at least one network interface.", ed_vm_iface), - # (software_package_iface_net, "software_package_iface_net", "All software packages can see the interfaces they need through a common network.", ed_software_package_iface_net), - # (iface_uniq, "iface_uniq", "There are no duplicated interfaces.", ed_iface_uniq), - # (all_SoftwareComponents_deployed, "all_SoftwareComponents_deployed", "All software components have been deployed to some node.", ed_all_SoftwareComponents_deployed), - # (all_infrastructure_elements_deployed, "all_infrastructure_elements_deployed", "All abstract infrastructure elements are mapped to an element in the active concretization.", ed_all_infrastructure_elements_deployed), - # (all_concrete_map_something, "all_concrete_map_something", "All elements in the active concretization are mapped to some abstract infrastructure element.", ed_all_concrete_map_something) - # ], DOMLVersion.V2_0: [ (vm_iface, "vm_iface", "All virtual machines must be connected to at least one network interface.", ed_vm_iface), @@ -732,6 +905,23 @@ RequirementLists = { # TODO: Fix rule # (external_services_must_have_https, "external_services_must_have_https", "All external SaaS should be accessed through HTTPS.", ed_external_services_must_have_https) ], + DOMLVersion.V2_3: [ + (vm_iface_v2_3, "vm_iface", + "All virtual machines must be connected to at least one network interface.", ed_vm_iface), + (software_package_iface_net_v2_3, "software_package_iface_net", + "All software packages can see the interfaces they need through a common network.", ed_software_package_iface_net), + (iface_uniq, "iface_uniq", "There are no duplicated interfaces.", ed_iface_uniq), + (all_SoftwareComponents_deployed, "all_SoftwareComponents_deployed", + "All software components have been deployed to some node.", ed_all_SoftwareComponents_deployed), + (all_infrastructure_elements_deployed, "all_infrastructure_elements_deployed", + "All abstract infrastructure elements are mapped to an element in the active concretization.", ed_all_infrastructure_elements_deployed), + (all_concrete_map_something, "all_concrete_map_something", + "All elements in the active concretization are mapped to some abstract infrastructure element.", ed_all_concrete_map_something), + (security_group_must_have_iface, "security_group_must_have_iface", + "All security group should be a associated to a network interface", ed_security_group_must_have_iface), + # TODO: Fix rule + # (external_services_must_have_https, "external_services_must_have_https", "All external SaaS should be accessed through HTTPS.", ed_external_services_must_have_https) + ], } diff --git a/mc_openapi/doml_mc/intermediate_model/metamodel.py b/mc_openapi/doml_mc/intermediate_model/metamodel.py index 186c68a962f0ecd22f41fdef41906adf1673d522..a91d6b0ee4e35f4a40bc85d5db2ade84005eb7e8 100644 --- a/mc_openapi/doml_mc/intermediate_model/metamodel.py +++ b/mc_openapi/doml_mc/intermediate_model/metamodel.py @@ -15,6 +15,7 @@ class DOMLVersion(Enum): V2_1 = "v2.1" V2_2 = "v2.2" V2_2_1 = "v2.2.1" + V2_3 = "v2.3" def get(v: str): """Retrieve DOML version from string. diff --git a/mc_openapi/doml_mc/mc.py b/mc_openapi/doml_mc/mc.py index 617d490e573beeacb5579c7f6cc0fea327b52e3d..3ef13ff6f339a22b9157b36ee91b0cc18bb364be 100644 --- a/mc_openapi/doml_mc/mc.py +++ b/mc_openapi/doml_mc/mc.py @@ -71,6 +71,7 @@ class ModelChecker: rfrom, rto) for rfrom, rto in split_reqs(len(req_store), threads)) # Uncomment for ease of debug + # Disables parallel parsing # results =[ worker(0, len(req_store) )] ret = MCResults([]) diff --git a/mc_openapi/doml_mc/xmi_parser/special_parsers.py b/mc_openapi/doml_mc/xmi_parser/special_parsers.py index d523391c62cb04b6e138598a8f3d8d41672c047a..8afa0daf7927c895e04b92653423b5c525bc22eb 100644 --- a/mc_openapi/doml_mc/xmi_parser/special_parsers.py +++ b/mc_openapi/doml_mc/xmi_parser/special_parsers.py @@ -74,6 +74,12 @@ def init_special_parsers(): ("infrastructure_ComputingNode", "memory_mb"): parse_memory_mb, ("commons_FProperty", "value"): parse_fproperty, }, + DOMLVersion.V2_3: { + ("infrastructure_Network", "addressRange"): parse_cidr, + ("infrastructure_NetworkInterface", "endPoint"): parse_iface_address, + ("infrastructure_ComputingNode", "memory_mb"): parse_memory_mb, + ("commons_FProperty", "value"): parse_fproperty, + }, } for ver in DOMLVersion: SpecialParsers[ver] = SpecialParser(MetaModels[ver], attribute_parsers[ver]) diff --git a/tests/doml/v2.3/UC3_Simplified.doml b/tests/doml/v2.3/UC3_Simplified.doml new file mode 100644 index 0000000000000000000000000000000000000000..93e3e5b0fce02f66bed954c8bb73132d8c779544 --- /dev/null +++ b/tests/doml/v2.3/UC3_Simplified.doml @@ -0,0 +1,294 @@ +doml uc3_openstack + +application app { + + // need to define all sw components of the project this is a placeholder + // need to understand what is really needed in this spec + // need to specify all provides/consumes + + software_component iwg { + provides { net_info } + } + software_component osint { + provides { osint_info } + consumes { net_info, get_twitter, ewcf_rest_interface } + } + software_component ewcf { + provides { ewcf_rest_interface } + consumes { get_firebase } + } + saas external_twitter { + provides { get_twitter @ "https://twitter_api/get" } + } + saas external_firebase { + provides { get_firebase @ "https://firebase_api/get" } + } + +} + +infrastructure infra { + // Giuseppe - tutti devono collegarsi a oam + // Giuseppe - igw deve avere reti oam la net1 verso osint e net2 verso network 5G + + // VMs region + vm igw_vm { + os "Ubuntu-Focal-20.04-Daily-2022-04-19" + size "small" + + iface igw_vm_oam { + belongs_to subnet_oam_igw + } + + iface igw_vm_net1 { + belongs_to subnet_net1_igw + } + + iface igw_vm_net2 { + belongs_to subnet_net2_igw + } + + credentials ssh_key + } + + // Giuseppe - osint deve avere reti oam la net1 verso igw e net3 verso network internet + vm osint_vm { + os "Ubuntu-Focal-20.04-Daily-2022-04-19" + size "small" + + iface osint_vm_oam { + belongs_to subnet_oam_osint + } + + iface osint_vm_net1 { + belongs_to subnet_net1_osint + } + + iface osint_vm_net3 { + belongs_to subnet_net3_osint + } + + credentials ssh_key + } + + // Giuseppe - ewcf deve avere reti oam la net1 verso osint e net3 verso network internet + vm ewcf_vm { + os "Ubuntu-Focal-20.04-Daily-2022-04-19" + size "small" + + iface ewcf_vm_oam { + belongs_to subnet_oam_ewcf + } + + iface ewcf_vm_net1 { + belongs_to subnet_net1_ewcf + } + + iface ewcf_vm_net3 { + belongs_to subnet_net3_ewcf + } + + credentials ssh_key + } + + // Network region + + // Internal Network + net oam { + protocol "TCP/IP" + cidr "16.0.0.0/24" + + subnet subnet_oam_igw { + protocol "TCP/IP" + cidr "16.0.1.0/26" + } + + subnet subnet_oam_osint { + protocol "TCP/IP" + cidr "16.0.1.64/26" + } + + subnet subnet_oam_ewcf { + protocol "TCP/IP" + cidr "16.0.1.128/26" + } + } + + // Internal network + net net1 { + protocol "TCP/IP" + cidr "16.0.1.0/24" + + // Subnets definition + subnet subnet_net1_igw { + connections { + subnet_net1_osint + } + protocol "TCP/IP" + cidr "16.0.1.0/25" + } + + subnet subnet_net1_osint { + connections { + subnet_net1_igw + subnet_net1_ewcf + } + protocol "TCP/IP" + cidr "16.0.1.64/26" + } + + subnet subnet_net1_ewcf { + connections { + subnet_net1_osint + } + protocol "TCP/IP" + cidr "16.0.1.128/26" + } + } + + // Network connecting igw to 5G + net net2 { + protocol "TCP/IP" + cidr "16.0.2.0/24" + + subnet subnet_net2_igw { + protocol "TCP/IP" + cidr "16.0.2.0/25" + } + + gateway net2_igw { + // TODO: Define address + address "16.0.2.22" + } + + } + + // Network connecting osint and ewcf to Internet + net net3 { + protocol "TCP/IP" + cidr "16.0.3.0/24" + + subnet subnet_net3_osint { + protocol "TCP/IP" + cidr "16.0.3.0/25" + } + + subnet subnet_net3_ewcf { + protocol "TCP/IP" + cidr "16.0.3.128/25" + } + + gateway net3_igw { + // TODO: Define address + address "16.0.3.22" + } + } + + // credentials region + key_pair ssh_key { + user "ubuntu" + keyfile "AAAAB3NzaC1yc2EAAAADAQABAAABAQC63ZvocMhX1LsdUlhzqLNSsh/Wotk/EMfDfa9pBHC52NXv05uENTjd/LBj8PS5JXEr7rKG9Zpj2Kj/PA7Gu0X1BZMwAiNR2dKjw9K0HO6Ozj3elCA7WjjotiQcO+OLWefE1PUW8/BJjtjFD/qf6wJd8CwInH8cjpkccQQfA55IXXegQMm5qv2a/S2XBvMMzv1dzsCy5UPO7tiOz4RBfi56JK8o2mDR327yY7+goA0HQz5tSN1X98+vxLpTPD5qINEFfVk1yNmf/ls3C7EBZQFJ6tsHgl070ymdBLHccmDMEYktzBnc/IhNWMq7K4IxwgFfQ7YSzAAqMr1n04+3oUeB" + algorithm "RSA" + bits 4096 + } + + // Security region + + // security group is left as originally defined needs to be updated + security_group sg { + egress icmp { + protocol "ICMP" + from_port -1 + to_port -1 + cidr ["0.0.0.0/0"] + } + ingress http { + protocol "TCP" + from_port 80 + to_port 80 + cidr ["0.0.0.0/0"] + } + ingress https { + protocol "TCP" + from_port 443 + to_port 443 + cidr ["0.0.0.0/0"] + } + ingress ssh { + protocol "TCP" + from_port 22 + to_port 22 + cidr ["0.0.0.0/0"] + } + + ifaces igw_vm_oam, igw_vm_net1, igw_vm_net2, osint_vm_oam, osint_vm_net1, osint_vm_net3, ewcf_vm_oam, ewcf_vm_net1, ewcf_vm_net3 + } +} + +deployment config1 { + osint -> osint_vm, + iwg -> igw_vm, + ewcf -> ewcf_vm +} + +active deployment config1 + +concretizations { + concrete_infrastructure con_infra { + + provider openstack { + + // Concrete computing nodes region + + vm concrete_osint_vm { + maps osint_vm + } + + vm concrete_igw_vm { + maps igw_vm + } + + vm concrete_ewcf_vm { + maps ewcf_vm + } + + // Concrete Network region + net concrete_oam { + maps oam + } + + net concrete_net1 { + maps net1 + } + + net concrete_net2 { + maps net2 + } + + net concrete_net3 { + maps net3 + } + + } + } + active con_infra +} + +// It's currently not possible to provide "storage" for OPEN provider (IOP) +// req4 "elements" => "VM, storage"; +// Required performance was too much (70%), modified after talking with Eneko + +optimization opt { + + objectives { + "cost" => min + "performance" => max + "availability" => max + } + nonfunctional_requirements { + req1 "Cost <= 300" max 300.0 => "cost"; + req2 "Performance >= 7%" min 7.0 => "performance"; + req3 "Provider" values "OPEN" => "provider"; + req4 "elements" => "VM, VM, VM"; + } + +} \ No newline at end of file