Class DeploymentNode


public final class DeploymentNode
extends DeploymentElement

Represents a deployment node, which is something like:

  • Physical infrastructure (e.g. a physical server or device)
  • Virtualised infrastructure (e.g. IaaS, PaaS, a virtual machine)
  • Containerised infrastructure (e.g. a Docker container)
  • Database server
  • Java EE web/application server
  • Microsoft IIS
  • etc
  • Constructor Details

  • Method Details

    • add

      public SoftwareSystemInstance add​(SoftwareSystem softwareSystem)
      Adds a software system instance to this deployment node, replicating relationships.
      Parameters:
      softwareSystem - the SoftwareSystem to add an instance of
      Returns:
      a SoftwareSystemInstance object
    • add

      public SoftwareSystemInstance add​(SoftwareSystem softwareSystem, java.lang.String... deploymentGroups)
      Adds a software system instance to this deployment node, replicating relationships.
      Parameters:
      softwareSystem - the SoftwareSystem to add an instance of
      deploymentGroups - the deployment group(s)
      Returns:
      a SoftwareSystemInstance object
    • add

      public ContainerInstance add​(Container container)
      Adds a container instance to this deployment node, replicating relationships.
      Parameters:
      container - the Container to add an instance of
      Returns:
      a ContainerInstance object
    • add

      public ContainerInstance add​(Container container, java.lang.String... deploymentGroups)
      Adds a container instance to this deployment node, optionally replicating relationships.
      Parameters:
      container - the Container to add an instance of
      deploymentGroups - the deployment group(s)
      Returns:
      a ContainerInstance object
    • addDeploymentNode

      public DeploymentNode addDeploymentNode​(java.lang.String name)
      Adds a child deployment node.
      Parameters:
      name - the name of the deployment node
      Returns:
      a DeploymentNode object
    • addDeploymentNode

      public DeploymentNode addDeploymentNode​(java.lang.String name, java.lang.String description, java.lang.String technology)
      Adds a child deployment node.
      Parameters:
      name - the name of the deployment node
      description - a short description
      technology - the technology
      Returns:
      a DeploymentNode object
    • addDeploymentNode

      public DeploymentNode addDeploymentNode​(java.lang.String name, java.lang.String description, java.lang.String technology, int instances)
      Adds a child deployment node.
      Parameters:
      name - the name of the deployment node
      description - a short description
      technology - the technology
      instances - the number of instances
      Returns:
      a DeploymentNode object
    • addDeploymentNode

      public DeploymentNode addDeploymentNode​(java.lang.String name, java.lang.String description, java.lang.String technology, int instances, java.util.Map<java.lang.String,​java.lang.String> properties)
      Adds a child deployment node.
      Parameters:
      name - the name of the deployment node
      description - a short description
      technology - the technology
      instances - the number of instances
      properties - a Map (String,String) describing name=value properties
      Returns:
      a DeploymentNode object
    • getDeploymentNodeWithName

      public DeploymentNode getDeploymentNodeWithName​(java.lang.String name)
      Gets the DeploymentNode with the specified name.
      Parameters:
      name - the name of the deployment node
      Returns:
      the DeploymentNode instance with the specified name (or null if it doesn't exist).
    • getInfrastructureNodeWithName

      public InfrastructureNode getInfrastructureNodeWithName​(java.lang.String name)
      Gets the infrastructure node with the specified name.
      Parameters:
      name - the name of the infrastructure node
      Returns:
      the InfrastructureNode instance with the specified name (or null if it doesn't exist).
    • addInfrastructureNode

      public InfrastructureNode addInfrastructureNode​(java.lang.String name)
      Adds a child infrastructure node.
      Parameters:
      name - the name of the infrastructure node
      Returns:
      an InfrastructureNode object
    • addInfrastructureNode

      public InfrastructureNode addInfrastructureNode​(java.lang.String name, java.lang.String description, java.lang.String technology)
      Adds a child infrastructure node.
      Parameters:
      name - the name of the infrastructure node
      description - a short description
      technology - the technology
      Returns:
      an InfrastructureNode object
    • addInfrastructureNode

      public InfrastructureNode addInfrastructureNode​(java.lang.String name, java.lang.String description, java.lang.String technology, java.util.Map<java.lang.String,​java.lang.String> properties)
      Adds a child infrastructure node.
      Parameters:
      name - the name of the infrastructure node
      description - a short description
      technology - the technology
      properties - a Map (String,String) describing name=value properties
      Returns:
      an InfrastructureNode object
    • uses

      public Relationship uses​(DeploymentNode destination, java.lang.String description, java.lang.String technology)
      Adds a relationship between this and another deployment node.
      Parameters:
      destination - the destination DeploymentNode
      description - a short description of the relationship
      technology - the technology
      Returns:
      a Relationship object
    • uses

      public Relationship uses​(DeploymentNode destination, java.lang.String description, java.lang.String technology, InteractionStyle interactionStyle)
      Adds a relationship between this and another deployment node.
      Parameters:
      destination - the destination DeploymentNode
      description - a short description of the relationship
      technology - the technology
      interactionStyle - the interaction style (Synchronous vs Asynchronous)
      Returns:
      a Relationship object
    • uses

      public Relationship uses​(DeploymentNode destination, java.lang.String description, java.lang.String technology, InteractionStyle interactionStyle, java.lang.String[] tags)
      Adds a relationship between this and another deployment node.
      Parameters:
      destination - the destination DeploymentNode
      description - a short description of the relationship
      technology - the technology
      interactionStyle - the interaction style (Synchronous vs Asynchronous)
      tags - an array of tags
      Returns:
      a Relationship object
    • uses

      public Relationship uses​(InfrastructureNode destination, java.lang.String description, java.lang.String technology)
      Adds a relationship between this deployment node and an infrastructure node.
      Parameters:
      destination - the destination InfrastructureNode
      description - a short description of the relationship
      technology - the technology
      Returns:
      a Relationship object
    • uses

      public Relationship uses​(InfrastructureNode destination, java.lang.String description, java.lang.String technology, InteractionStyle interactionStyle)
      Adds a relationship between this deployment node and an infrastructure node.
      Parameters:
      destination - the destination InfrastructureNode
      description - a short description of the relationship
      technology - the technology
      interactionStyle - the interaction style (Synchronous vs Asynchronous)
      Returns:
      a Relationship object
    • uses

      public Relationship uses​(InfrastructureNode destination, java.lang.String description, java.lang.String technology, InteractionStyle interactionStyle, java.lang.String[] tags)
      Adds a relationship between this deployment node and an infrastructure node.
      Parameters:
      destination - the destination InfrastructureNode
      description - a short description of the relationship
      technology - the technology
      interactionStyle - the interaction style (Synchronous vs Asynchronous)
      tags - an array of tags
      Returns:
      a Relationship object
    • getChildren

      public java.util.Set<DeploymentNode> getChildren()
      Gets the set of child deployment nodes.
      Returns:
      a Set of DeploymentNode objects
    • getInfrastructureNodes

      public java.util.Set<InfrastructureNode> getInfrastructureNodes()
      Gets the set of child infrastructure nodes.
      Returns:
      a Set of InfrastructureNode objects
    • hasChildren

      public boolean hasChildren()
    • getSoftwareSystemInstances

      public java.util.Set<SoftwareSystemInstance> getSoftwareSystemInstances()
      Gets the set of software system instances associated with this deployment node.
      Returns:
      a Set of SoftwareSystemInstance objects
    • getContainerInstances

      public java.util.Set<ContainerInstance> getContainerInstances()
      Gets the set of container instances associated with this deployment node.
      Returns:
      a Set of ContainerInstance objects
    • getTechnology

      public java.lang.String getTechnology()
    • setTechnology

      public void setTechnology​(java.lang.String technology)
    • getInstances

      public int getInstances()
    • setInstances

      public void setInstances​(int instances)
    • getRequiredTags

      protected java.util.Set<java.lang.String> getRequiredTags()
      Specified by:
      getRequiredTags in class ModelItem
    • getCanonicalName

      public java.lang.String getCanonicalName()
      Specified by:
      getCanonicalName in class ModelItem