Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseCommissioned_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Commission Control Loop Type Definition
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Store Control Loop Type Definition
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definition Commissioned
@enduml

...

PlantUML Macro
@startuml
participant SDC
participant Policy_Distribution
participant CLAMP_Runtime
database DatabaseCommissioned_CL_Inventory

SDC -> Policy_Distribution: [DMaaP] CSAR containing Control Loop Type Definition
Policy_Distribution -> CLAMP_Runtime: [REST] Commission Control Loop Type Definition
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Store Control Loop Type Definition
CLAMP_Runtime -> Policy_Distribution: [REST] Type Definition Commissioned
Policy_Distribution -> SDC: [DMaaP] Deployment Completed
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
participant Participant
database DatabaseCommissioned_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Type Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definitions returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Type Definition for Parameterization
CLAMP_GUI -> CLAMP_Runtime: [REST] Fetch GUI fields for Common Parameter Definitions

alt Control Loop Type Definition not Commissioned on Participants
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definition
  CLAMP_Runtime -> CLAMP_Runtime: Generate fields for Common Parameters for GUI
  CLAMP_Runtime -> CLAMP_GUI: [REST] Return GUI fields Common Parameter Definitions
  CLAMP_GUI -> CLAMP_GUI: Render UI for Common Parameters
  CLAMP_GUI -> CLAMP_GUI: Get values for Common Parameters from user
  CLAMP_GUI -> CLAMP_Runtime: [REST] Set values for Common Parameters
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Store values for Common Parameters
  CLAMP_Runtime -> CLAMP_GUI: [REST] Common Parameter values stored
else Control Loop Type Definition already Commissioned on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] Cannot set Common Parameters on\nControl Loop Type Definition that has\nbeen commissioned on participants
end

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
participant Participant
database DatabaseCommissioned_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Type Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definitions returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Type Definition for Priming on Participants
CLAMP_GUI -> CLAMP_Runtime: [REST] Prime Control Loop Type Definition on Participants

alt Control Loop Type Definition not Primed on Participants
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definition
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Common Parameter Values for Control Loop Type Definition
  alt Common Parameter values set for Control Loop Type Definition
    CLAMP_Runtime -> Participants: [DMaaP] Update Participants with Control Loop Type Definition and values for Common Parameters
    CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Type Definition priming ordered on participants
  else Control Loop Type Definition already primed on Participants
    CLAMP_Runtime -> CLAMP_GUI: [REST] Common Parameters not set\non Control Loop Type Definition
  end
else Control Loop Type Definition already primed on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] Cannot set Common Parameters on\nControl Loop Type Definition that has\nbeen primed on participants
end

== Participant Responses ==
Participants -> CLAMP_Runtime: [DMaaP] Result of Update with Control Loop Type Definition and values for Common Parameters
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Store result of Control Loop Type Definition Update on Participant

== Supervision ==
loop forever
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
  loop over each Control Loop Type Definition
    alt Control Loop Type Definition Participant priming underway
	  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: read result of Control Loop Type Definition Updates from participants
      alt Updates completed on all participants
	    CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: set Control Loop Type Definition as primed on Participants
      else Updates not completed
        alt Priming of Control Loop Type Definition on participants timed out
	      CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: set Control Loop Type Definition priming as timed out on Participants
	      CLAMP_Runtime -> CLAMP_Runtime: Log error
        else Wait for updates to complete
        end
      end 
    else Control Loop Type Definition Participant priming not underway
    end
  end
end
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
participant Participant
database DatabaseCommissioned_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Type Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definitions returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Type Definition for de-priming on Participants
CLAMP_GUI -> CLAMP_Runtime: [REST] De-prime Control Loop Type Definition on Participants

alt Control Loop Type Definition primed on Participants
  alt Control Loop Instances do not exist for Control Loop Type Definition
    CLAMP_Runtime -> Participants: [DMaaP] Update Participants, removing Control Loop Type Definition and values for Common Parameters
    CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Type Definition de-priming ordered on participants
  else Control Loop Instances exist for Control Loop Type Definition
    CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Type Definition cannot be\n de-primed on participants\nit is in use on control loops
  end
else Control Loop Type Definition not primed on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Type Definition has not\nbeen primed on participants
end

== Participant Responses ==
Participants -> CLAMP_Runtime: [DMaaP] Result of Update to remove Control Loop Type Definition and values for Common Parameters
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Store result of Control Loop Type Definition Update on Participant

== Supervision ==
loop forever
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
  loop over each Control Loop Type Definition
    alt Control Loop Type Definition Participant de-prime underway
	  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: read result of Control Loop Type Definition Updates from participants
      alt Updates completed on all participants
	    CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: set Control Loop Type Definition as de-primeed on Participants
      else Updates not completed
        alt De-priming of Control Loop Type Definition on participants timed out
	      CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: set Control Loop Type Definition de-priming as timed out on Participants
	      CLAMP_Runtime -> CLAMP_Runtime: Log error
        else Wait for updates to complete
        end
      end 
    else Control Loop Type Definition Participant de-prime not underway
    end
  end
end
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseCommissioned_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Type Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definitions returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Type Definition for Decommissioning
CLAMP_GUI -> CLAMP_Runtime: [REST] Decommission Control Loop Type Definition

alt Control Loop Type Definition not primed on Participants
  CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Delete Control Loop Type Definition
  CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definition Decommissioned
else Control Loop Type Definition is Commissioned on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Type Definition cannot be decommissioned\nit is primed on participants
end

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseCommissioned_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Type Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definitions returned

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseCommissioned_CL_Inventory
database Instantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Type Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definitions
CLAMP_Runtime -> CLAMP_GUI: [REST] Type Definitions returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Type Definition to use to create Control Loop Instance
CLAMP_GUI -> CLAMP_Runtime: [REST] Fetch GUI fields for Instance Specific Parameter Definitions
CLAMP_Runtime -> DatabaseCommissioned_CL_Inventory: Read Control Loop Type Definition
CLAMP_Runtime -> CLAMP_Runtime: Generate fields for Instance Specific Parameters for GUI
CLAMP_Runtime -> CLAMP_GUI: [REST] Return GUI fields Instance Specific Parameter Definitions
CLAMP_GUI -> CLAMP_GUI: Render UI for Instance Specific Parameters
CLAMP_GUI -> CLAMP_GUI: Get values for Instance Specific Parameters from user
CLAMP_GUI -> CLAMP_Runtime: [REST] Request Creation of Control Loop Instance
CLAMP_Runtime -> CLAMP_Runtime: Create Control Loop Instance
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store First Version of Control Loop Instance
CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instance Updated

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database Database

Instantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Instance on which to Update Parameters
CLAMP_GUI -> CLAMP_GUI: Step version of Control Loop Instance as Major/Minor/Patch
CLAMP_GUI -> CLAMP_Runtime: [REST] Fetch GUI fields for Instance Specific Parameter Definitions
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Type Definition
CLAMP_Runtime -> CLAMP_Runtime: Generate fields for Instance Specific Parameters for GUI
CLAMP_Runtime -> CLAMP_GUI: [REST] Return GUI fields Instance Specific Parameter Definitions
CLAMP_GUI -> CLAMP_GUI: Render UI for Instance Specific Parameters
CLAMP_GUI -> CLAMP_GUI: Get values for Instance Specific Parameters from user
CLAMP_GUI -> CLAMP_Runtime: [REST] Request Update of Control Loop Instance
CLAMP_Runtime -> CLAMP_Runtime: Update Control Loop Instance
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store New Version of Control Loop Instance
CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instance Updated

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
participant Participant
database DatabaseInstantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read all configuration versions of Control Loop Instance
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all configuration versions of Control Loop Instance
CLAMP_Runtime -> CLAMP_GUI: [REST] All configuration versions of Control Loop Instance returned
CLAMP_GUI -> CLAMP_GUI: Select configuration version of Control Loop Instance for Instantiation Participants
CLAMP_GUI -> CLAMP_Runtime: [REST] Instantiate selected configuration version of Control Loop Instance on Participants

alt Selected configuration version of Control Loop Instance not instantiated on Participants
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read configuration version of Control Loop Instance
  CLAMP_Runtime -> Participants: [DMaaP] Update Participants with configuration version of Control Loop Instance
  CLAMP_Runtime -> CLAMP_GUI: [REST] Instantiation of configuration version of Control Loop Instance ordered on participants
else Selected configuration version of Control Loop Instance instantiated on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] configuration version of Control Loop Instance already instantiated on participants 
end

== Participant Responses ==
Participants -> CLAMP_Runtime: [DMaaP] Result of update of configuration version of Control Loop Instance on participant
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store result of update of configuration version of Control Loop Instance on participant

== Supervision ==
loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Instances
  loop over each Control Loop Instance
    alt Control Loop Instance configuration version update underway on participants
	  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: read result of Control Loop updates from participants
      alt Updates completed on all participants
	    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set configuration version of Control Loop Instance as Instantiated on Participants
	    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set overall configuration version of Control Loop Instance state as Instantiated
      else Updates not completed
        alt Instantiation of Control Loop Instance on participants timed out
	      CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set configuration version Control Loop Instance Instantiation as timed out on Participants
	      CLAMP_Runtime -> CLAMP_Runtime: Log error
        else Wait for updates to complete
        end
      end 
    else Control Loop Instance configuration version update on participants not underway
    end
  end
end
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
participant Participant
database DatabaseInstantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read all Instantiated Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all Instantiated Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] All Instantiated Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Instance on which to change state and specify new state
CLAMP_GUI -> CLAMP_Runtime: [REST] Change state of selected Control Loop Instance on Participants

alt Selected Control Loop Instance instantiated on Participants
  CLAMP_Runtime -> Participants: [DMaaP] Request change of state of Control Loop Instance
  CLAMP_Runtime -> CLAMP_GUI: [REST] Change of state of Control Loop Instance ordered on participants
else Selected Control Loop Instance not instantiated on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instance not instantiated on participants 
end

== Participant Responses ==
Participants -> CLAMP_Runtime: [DMaaP] Result of State Change of Control Loop Instance on participant
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store result of State Change of Control Loop Instance on participant

== Supervision ==
loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Instances
  loop over each Control Loop Instance
    alt Control Loop Instance State Change underway on participants
	  CLAMP_Runtime -> Database:Instantiated_CL_Inventory: read result of Control Loop State Change from participants
      alt Updates completed on all participants
	    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set Control Loop Instance state as changed on Participants
	    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set overall Control Loop Instance state as changed
      else Updates not completed
        alt Control Loop Instance State Change on participants timed out
	      CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set Control Loop State Change as timed out on Participants
	      CLAMP_Runtime -> CLAMP_Runtime: Log error
        else Wait for updates to complete
        end
      end 
    else Control Loop Instance State Change on participants not underway
    end
  end
end
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
participant Participant
database DatabaseInstantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read all Instantiated Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all Instantiated Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] All Instantiated Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Instance to de-instantiate
CLAMP_GUI -> CLAMP_Runtime: [REST] De-instantiate selected Control Loop Instance on Participants

alt Selected Control Loop Instance instantiated on Participants
  CLAMP_Runtime -> Participants: [DMaaP] Update Participants to remove Control Loop Instance
  CLAMP_Runtime -> CLAMP_GUI: [REST] De-instantiation of Control Loop Instance ordered on participants
else Selected Control Loop Instance not instantiated on Participants
  CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instance not instantiated on participants 
end

== Participant Responses ==
Participants -> CLAMP_Runtime: [DMaaP] Result of update of Control Loop Instance on participant
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store result of update of Control Loop Instance on participant

== Supervision ==
loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Instances
  loop over each Control Loop Instance
    alt Control Loop Instance de-instantiation update underway on participants
	  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: read result of Control Loop updates from participants
      alt Updates completed on all participants
	    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set Control Loop Instance as de-instantiated on Participants
	    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set overall Control Loop Instance as de-instantiated
      else Updates not completed
        alt Control Loop Instance de-instantiation Update timed out on participants
	      CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: set Control Loop Instance de-instantiation as timed out on Participants
	      CLAMP_Runtime -> CLAMP_Runtime: Log error
        else Wait for updates to complete
        end
      end 
    else Control Loop Instance de-instantiation update on participants not underway
    end
  end
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime

database DatabaseInstantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read all Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] All Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Select Control Loop Instance to delete
CLAMP_GUI -> CLAMP_Runtime: [REST] Delete selected Control Loop Instance

alt Selected Control Loop Instance exists
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Delete control loop instance
  CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instance deleted
else Selected Control Loop Instance does not exist
  CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Instance does not exist 
end

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseInstantiated_CL_Inventory

CLAMP_GUI -> CLAMP_Runtime: [REST] Read all Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] All Control Loop Instances returned

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_Runtime
participant Participant
database DatabaseInstantiated_CL_Inventory

Participant -> CLAMP_Runtime: [DMaaP] Participant and Control Loop Element Monitoring and Statistics report
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store Participant and Control Loop Element Monitoring and Statistics report

alt Fault reported on Participant
  CLAMP_Runtime -> CLAMP_Runtime: log fault on Participant
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record fault on Participant
end

loop Over all Control Loop Elements in Participant Report
  alt Fault reported on Control Loop Element
    CLAMP_Runtime -> CLAMP_Runtime: log fault on Control Loop Element and Control Loop
    CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record fault on Control Loop Element and Control Loop
  end
end
@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseInstantiated_CL_Inventory

== Overview of all Control Loop Instances ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read all Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] All Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Display overview of status of all Control Loop Instances

== Details of a Control Loop Instance ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Elements for Control Loop Instance
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Elements for Control Loop Instance
CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Elements returned
CLAMP_GUI -> CLAMP_GUI: Display status of Control Loop Elements in Control Loop Instance

== Overview of all Participants ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read all participants
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read all participants
CLAMP_Runtime -> CLAMP_GUI: [REST] All participants returned
CLAMP_GUI -> CLAMP_GUI: Display overview of status of all participants

== Details of a Participant ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Elements for Participant
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Elements for Participant
CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Elements returned
CLAMP_GUI -> CLAMP_GUI: Display status of Control Loop Elements in Participant

== Filtered Monitoring ==
CLAMP_GUI -> CLAMP_GUI: Set filter for Control Loop Instances, Control Loop Elements, and Participants
CLAMP_GUI -> CLAMP_Runtime: [REST] Read Control Loop Elements that match filter
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Elements that match filter
CLAMP_Runtime -> CLAMP_GUI: [REST] Control Loop Elements that match filter returned
CLAMP_GUI -> CLAMP_GUI: Display status of Control Loop Elements that match filter

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_GUI
participant CLAMP_Runtime
database DatabaseInstantiated_CL_Inventory

== Statistics of all Control Loop Instances ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read summary statistics for all Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Compile summary statistics for all Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] Summary statistics for all Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Display summary statistics for all Control Loop Instances

== Statistics of a Control Loop Instance ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read statistics for Control Loop Elements for Control Loop Instance
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Compile statistics for Control Loop Elements for Control Loop Instance
CLAMP_Runtime -> CLAMP_GUI: [REST] Statistics for Control Loop Elements returned
CLAMP_GUI -> CLAMP_GUI: Display statistics for Control Loop Elements in Control Loop Instance

== Statistics of all Participants ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read summary statistics for all Control Loop Instances
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Compile summary statistics for all Control Loop Instances
CLAMP_Runtime -> CLAMP_GUI: [REST] Summary statistics for all Control Loop Instances returned
CLAMP_GUI -> CLAMP_GUI: Display summary statistics for all Control Loop Instances

== Statistics of a Participant ==
CLAMP_GUI -> CLAMP_Runtime: [REST] Read statistics for Control Loop Elements for Participant
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read statistics for Control Loop Elements for Participant
CLAMP_Runtime -> CLAMP_GUI: [REST] Statistics for Control Loop Elements returned
CLAMP_GUI -> CLAMP_GUI: Display statistics for Control Loop Elements in Participant

== Filtered Statistics ==
CLAMP_GUI -> CLAMP_GUI: Set filter for Control Loop Instances, Control Loop Elements, and Participants
CLAMP_GUI -> CLAMP_Runtime: [REST] Read statistics for Control Loop Elements that match filter
CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read statistics for Control Loop Elements that match filter
CLAMP_Runtime -> CLAMP_GUI: [REST] Statistics for Control Loop Elements that match filter returned
CLAMP_GUI -> CLAMP_GUI: Display statistics for Control Loop Elements that match filter

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_Runtime
database DatabaseInstantiated_CL_Inventory

== Control Loop Instance Statistics ==

loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Instance Statistics
  CLAMP_Runtime -> CLAMP_Runtime: Summarise Control Loop Instance Statistics
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store summarised Control Loop Instance Statistics
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Delete Control Loop Instance Statistics on which retention period has expired
end

== Participant Statistics ==

loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Participant Statistics
  CLAMP_Runtime -> CLAMP_Runtime: Summarise Participant Statistics
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Store summarised Participant Statistics
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Delete Participant Statistics on which retention period has expired
end

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_Runtime
database DatabaseInstantiated_CL_Inventory

loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Participants
  loop Over each Participant
    alt Participant has not reported in last reporting window
       CLAMP_Runtime -> CLAMP_Runtime: Log Participant as having missed a report
       CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Increment missed report counter on Participant
       alt Participant has exceeded alarm threshold on missed report counter
          CLAMP_Runtime -> CLAMP_Runtime: Raise a Participant Offline alarm on participant
          CLAMP_Runtime -> Database Instantiated_CL_Inventory: Mark participant as being offline
       end
    else Participant has reported in last reporting window
       CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Clear missed report counter on Participant
       alt Participant marked as being offline
          CLAMP_Runtime -> CLAMP_Runtime: Clear Participant Offline alarm on participant
          CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Mark participant as being online
       end
    end
  end
end

@enduml

...

PlantUML Macro
@startuml
participant CLAMP_Runtime
database DatabaseInstantiated_CL_Inventory

loop forever
  CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Read Control Loop Instances
  loop Over each Control Loop Instance
    loop Over each Control Loop Element
      alt Control Loop Element has not reported in last reporting window
         CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Element as having missed a report
         CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Increment missed report counter on Control Loop Element
      else Control Loop Element has reported in last reporting window
         CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Clear missed report counter on Control Loop Element
      end
      alt Control Loop Element in incorrect state in last reporting window
        CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Element as being in incorrect state
        CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Element as being in incorrect state
      else Control Loop Element not in incorrect state in last reporting window
        alt Control Loop Element was in incorrect state on previous report
          CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Element as being in correct state
          CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Element as being in correct state
        end
      end
      alt Control Loop Element reported fault in last reporting window
        CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Element as being faulty
        CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Element as being faulty
      else Control Loop Element did not report fault in last reporting window
        alt Control Loop Element reported fault on previous report
          CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Element fault as cleared
          CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Mark fault Control Loop Element as being cleared
        end
      end
    end
    alt Control Loop Element in Control Loop Instance has exceeded alarm threshold on missed report counter
      CLAMP_Runtime -> CLAMP_Runtime: Raise a Control Loop Offline alarm on Control Loop Instance
      CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Mark Control Loop Instance as being offline
    else No Control Loop Element in Control Loop Instance has exceeded alarm threshold on missed report counter
       alt Control Loop Instance marked as being offline
          CLAMP_Runtime -> CLAMP_Runtime: Clear Control Loop Instance Offline alarm on Control Loop
          CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Mark Control Loop Instance as being online
       end
    end
    alt Control Loop Element in Control Loop Instance in incorrect state in last reporting window
      CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Instance as being in incorrect state
      CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Instance as being in incorrect state
      alt Control Loop Element in Control Loop Instance has exceeded alarm threshold on incorrect state reports
        CLAMP_Runtime -> CLAMP_Runtime: Raise a Control Loop Instance in Incorrect State alarm on Control Loop Instance
        CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Mark Control Loop Instance as being in an incorrect state
      end
    else No Control Loop Element in incorrect state in last reporting window
      alt Control Loop Element in Control Loop Instance was in incorrect state on previous report
        CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Instance as being in correct state
        CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Instance as being in correct state
        alt Control Loop Instance in Incorrect State alarm raised on Control Loop Instance
          CLAMP_Runtime -> CLAMP_Runtime: Clear Control Loop Instance in Incorrect State alarm on Control Loop Instance
        end
      end
    end
    alt Control Loop Element in Control Loop Instance reported a fault in last reporting window
      CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Instance as being faulty
      CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Instance as being faulty
      alt Control Loop Element in Control Loop Instance has exceeded alarm threshold on faulty reports
        CLAMP_Runtime -> CLAMP_Runtime: Raise a Control Loop Instance Faulty alarm on Control Loop Instance
      end
    else No Control Loop Element faulty in last reporting window
      alt Control Loop Element in Control Loop Instance was faulty on previous report
        CLAMP_Runtime -> CLAMP_Runtime: Log Control Loop Instance as being fault free
        CLAMP_Runtime -> DatabaseInstantiated_CL_Inventory: Record Control Loop Instance as being fault free
        alt Control Loop Instance Faulty alarm raised on Control Loop Instance
          CLAMP_Runtime -> CLAMP_Runtime: Clear Control Loop Instance Faulty alarm on Control Loop Instance
        end
      end
    end
  end
end

@enduml

...