...
PlantUML Macro |
---|
@startuml participant Participant participant ACM_Runtime database ACM_Database Participant -> ACM_Runtime: [ASYNC] Register ACM_Runtime -> ACM_Database: [ASYNC] Create or Update Participant Registration\nand store supported ACM element types ACM_Runtime -> ACM_Database: Set Participant State as ONLINE Participant <- ACM_Runtime: Registration Accepted ACM_Runtime -> ACM_Runtime: Mark all ACM Element Instances\nrunning on Participant as ONLINE activate ACM_Runtime deactivate ACM_Runtime @enduml |
1.2 Deregister a Participant
...
PlantUML Macro |
---|
@startuml participant Participant participant ACM_Runtime database ACM_Database Participant -> Participant: Uninitialize all ACM Element Instances running on Participant\n(See Instantiation Dialogues) activate Participant deactivate Participant ACM_RuntimeParticipant -> ACM_DatabaseRuntime: Delete Participant Registration Participant [ASYNC] Deregister ACM_Runtime -> ACM_Database: Delete Participant Registration ACM_Runtime -> ACM_Database: Set Participant State as OFFLINE Participant <- ACM_Runtime: [ASYNC] Deregistration Accepted ACM_Runtime -> ACM_Runtime: Mark all ACM Element Instances\nrunning on Participant as OFFLINE activate ACM_Runtime deactivate ACM_Runtime @enduml |
1.3 Supervise Participants
...
PlantUML Macro |
---|
@startuml participant Participant participant ACM_Runtime database ACM_Database loop Every Participant Supervision Interval Participant -> ACM_Runtime: [ASYNC] Heartbeat message including\nstatus and states of AC Element Instances on Participant ACM_Runtime -> ACM_Database: Update Participant Heartbeat data ACM_Runtime -> ACM_Database: Set Participant State as ONLINE loop Every AC Element Instance in Heartbeat Message ACM_Runtime -> ACM_Database: Mark AC Element Instance as ONLINE\nand Update AC Element Instance status end end @enduml |
...
PlantUML Macro |
---|
@startuml participant ACM_Runtime database ACM_Database loop Every ACM_Runtime Supervision Interval loop Over all Participants ACM_Runtime -> Database: Read Participant Heartbeat Information alt Participant Heartbeat not received in Timeout Interval ACM_Runtime -> ACM_Database: Set Participant State as OFFLINE ACM_Runtime -> ACM_Runtime: Mark all ACM Element Instances\nrunning on Participant as OfflineOFFLINE activate ACM_Runtime deactivate ACM_Runtime end end end @enduml |
...
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime database ACM_Database REST -> ACM_Runtime: Commission Automation Composition Type alt Automation Composition Type exists and has Instances ACM_Runtime -> REST: Automation Composition Type Commissioning Failed else ACM_Runtime -> ACM_Database: Create and Store Automation Composition Type ACM_Runtime -> RESTACM_Database: Set Automation Composition Type Commissioned end State to COMMISSIONED ACM_Runtime -> REST: Automation Composition Type Commissioned end @enduml |
2.2 Commission an Automation Composition Type using SDC
...
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime database ACM_Database REST -> ACM_Runtime: Decommission Automation Composition Type alt Automation Composition Type has Instancesis not in state COMMISSIONED ACM_Runtime -> REST: Automation Composition Type Decommissioning Failed else ACM_Runtime -> ACM_Database: Delete Automation Composition Type ACM_Runtime -> REST: Automation Composition Type Decommissioned end @enduml |
...
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime participant Participant database ACM_Database alt Automation Composition Type has Deployed Instances REST <-> ACM_Runtime: Priming Primeof Automation Composition Type Failed, instances deployed ACM_Runtimeelse Automation Composition Type is in state COMMISSIONED or PRIMED REST -> ACM_DatabaseRuntime: ReadPrime Automation Composition Type ACM_Runtime -> ACM_Database: Read Automation Composition Type ACM_Runtime -> ACM_Database: Read Participants ACM_Runtime -> ACM_Runtime: Set suitable participant ID on each AC Element Type alt Was a sutable participant ID found for each AC Element Type? ACM_Runtime -> Participant: [ASYNC] Send Priming Request to all Participants\nwith Automation Composition Type Definition ACM_Runtime -> ACM_Database: Set Automation Composition Type State to PRIMING REST <- ACM_Runtime: Priming of Automation Composition Type Ordered else REST <- ACM_Runtime: Priming of Automation Composition Type Faield, no sutiable participant found end else REST <- ACM_Runtime: Priming of Automation Composition Type Failed, invalid state end @enduml |
A participant should respond for each Automation Composition Element Type, thus causing the full Automation Composition Type to become primed. Note that if more than one participant can support an Automation Composition Element Type the ACM Runtime uses the participant in the first response it receives for that Automation Composition Element Type.
PlantUML Macro |
---|
@startuml
participant ACM_Runtime
participant Participant
ACM_Runtime -> Participant: [ASYNC] Prime AC Element Types for this AC Type
loop over AC Element Types in AC Type
alt Does the primed Participant ID on this AC Element Type\nmatch my Participant ID
alt Does this AC Element Type already exist
ACM_Runtime <- Participant: [ASYNC] WARN: AC Element Type already exists
else
Participant -> Participant: Create AC Element Type
activate Participant
deactivate Participant
alt AC Element successfully created
ACM_Runtime <- Participant: [ASYNC] INFO: AC Element successfully primed
else
ACM_Runtime <- Participant: [ASYNC] ERROR: AC Element priming failed
end
end
else
note left of participant
ignore this AC Element Type as its for another participant
end note
end
end
@enduml |
The ACM Runtime updates the priming information in the database.
PlantUML Macro |
---|
@startuml
participant ACM_Runtime
participant Participant
database ACM_Database
ACM_Runtime <- Participant: [ASYNC] Result of Priming of AC Element Type
ACM_Runtime -> ACM_Database: Record result of AC Element Type Priming
alt Is AC Element Type Primed?
alt Have all the other AC Element Types in this AC Type been Primed?
ACM_Runtime -> ACM_Runtime: Set AC Type state as PRIMED
end
end
@enduml |
2.5 Deprime an Automation Composition Type on Participants
The Depriming operation removes Automation Composition Types and common property values on participants for each Automation Composition Element Type in the Automation Composition Type.
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime participant Participant database ACM_Database alt Automation Composition Type has Instances REST <- ACM_Runtime: Depriming of Automation Composition Type Failed else AC Type State is PRIMED or PRIMING REST -> ACM_Runtime: Deprime Automation Composition Type ACM_Runtime -> ACM_Database: Read Automation Composition Type ACM_Runtime -> Participant: [ASYNC] Send Depriming Request to all Participants\nwith Automation Composition Type Definition ACM_Runtime -> ParticipantACM_Database: Set [ASYNC]Automation SendComposition PrimingType RequestState to all Participants\nwith DEPRIMING REST <- ACM_Runtime: Depriming of Automation Composition Type DefinitionOrdered else REST <- ACM_Runtime: PrimingDepriming of Automation Composition Type Ordered Failed, invalid state end @enduml |
A participant should respond for each Automation Composition Element Type, thus causing the full Automation Composition Type to become primed. Note that if more than one participant can support an participant should respond for each Automation Composition Element Type the ACM Runtime uses the participant in the first response it receives for that Automation Composition Element Type, thus causing the full Automation Composition Type to become deprimed.
PlantUML Macro |
---|
@startuml participant ACM_Runtime participant Participant ACM_Runtime -> Participant: [ASYNC] PrimeDeprime AC Element Types for this AC Type loop over AC Element Types in AC Type alt Does the primeddeprimed Participant ID on this AC Element Type\nmatch my Participant ID alt IsDoes this AC Element Type already primedExist ACM_RuntimeParticipant <-> Participant: [ASYNC] WARN: Delete AC Element Type is alreadyactivate primedParticipant else deactivate Participant -> Participant: Primesnote ACleft Elementof TypeParticipant activate Deletion Participant of an AC deactivateElement Participant Type always returns altsuccess AC Element successfullyend primednote ACM_Runtime <- Participant: [ASYNC] INFO: AC Element successfully primed else ACM_Runtime <- Participant: [ASYNC] ERRORWARN: AC Element primingType failed is already enddeprimed end else note left of participantParticipant ignore this AC Element Type as its for another participant end note end end @enduml |
...
PlantUML Macro |
---|
@startuml participant ACM_Runtime participant Participant database ACM_Database ACM_Runtime <- Participant: [ASYNC] Result of Depriming of AC ACM_Database ACM_Runtime <- Participant: [ASYNC] Result of Priming ofElement Type ACM_Runtime -> ACM_Database: Record result of AC Element Type Depriming alt Is AC Element Type Deprimed? alt Have all the other AC Element Types in this AC Type been Deprimed? ACM_Runtime -> ACM_DatabaseRuntime: RecordSet resultAC ofType ACstate Elementas Type PrimingCOMMISSIONED end end @enduml |
2.
...
6 Get Automation Composition Types
This dialogue allows an Automation Composition Type to be read.
...
Instantiation dialogues are used to create, set parameters on, instantiate, update, and remove Automation Composition instances.
3.1 Create
...
an Automation Composition Instance
Create on a POST and update on a PUT.
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime database ACM_Database REST -> ACM_Runtime: Create Automation Composition Instance for\nspecified Automation Composition Type with\nspecified parameter values alt Automation Composition Instance exists alt Automation Composition Instance is isnot in alreadystate deployedUNDEPLOYED ACM_Runtime -> REST: Automation Composition instance exists and is already deployed else note right of REST Updates on "Not In Service" Automation Composition Instances are allowed end note end end alt Specified Automation Composition Type Composition Exists alt Specified Automation Composition Type is in state PrimedPRIMED ACM_Runtime -> ACM_Database: Store Automation Composition Instance ACM_Runtime -> ACM_Database: Set Automation Composition Instance State to UNDEPLOYED ACM_Runtime -> REST: Automation Composition Instance Created else ACM_Runtime -> REST: Automation Composition Type is not in state primedPRIMED end else ACM_Runtime -> REST: Automation Composition Type is not found end @enduml |
...
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime database ACM_Database REST -> ACM_Runtime: Delete Automation Composition Instance alt Automation Composition Instance exists alt Automation Composition Instance is deployed not in state UNDEPLOYED ACM_Runtime -> REST: Automation Composition instance exists and is deployed else ACM_Runtime -> REST: Automation Composition instance does not exist end else ACM_Runtime -> ACM_Database: Delete Automation Composition Instance ACM_Runtime -> REST: Automation Composition Instance Deleted end @enduml |
...
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime participant Participants database ACM_Database REST -> ACM_Runtime: Deploy Automation Composition Instance ACM_Runtime -> ACM_Database: Read Automation Composition Instance Information alt Automation Composition Instance exists alt Automation Composition Instance is deployed ACM_Runtime -> REST: Automation Composition instance is already deployed else ACM_Runtime -> REST: Automation Composition instance does not exist end else ACM_Runtime -> Participants: [ASYNC] Deploy AC Element Instances for this AC Instance ACM_Runtime -> ACM_Database: MarkSet AC Instance and its AC Element Instances asto state DeployingDEPLOYING ACM_Runtime -> REST: Deployment of Automation Composition Instance has been requested end else ACM_Runtime -> REST: Automation Composition instance does not exist end @enduml |
Each participant deploys its AC Element Instances from the AC Instance.
...
PlantUML Macro |
---|
@startuml participant ACM_Runtime participant Participant database ACM_Database ACM_Runtime <- Participant: [ASYNC] Deploy Automation Composition Element Instance Response ACM_Runtime -> ACM_Database: Store Automation Composition Element Instance Response Information alt Is AC Element Instance Deployed? ACM_Runtime -> ACM_Database: Set AC Element Instance administrative stateState as LOCKEDDEPLOYED alt HaveAre all the other AC Element Instances in this AC Instance beenin state deployedDEPLOYED? ACM_Runtime -> ACM_Runtime: Set AC Instance administrative state as LOCKEDDEPLOYED end end @enduml |
3.4 Undeploy Automation Composition Instance
...
PlantUML Macro |
---|
@startuml participant REST participant ACM_Runtime participant Participants database ACM_Database REST -> ACM_Runtime: Undeploy Automation Composition Instance ACM_Runtime -> ACM_Database: Read Automation Composition Instance Information alt Automation Composition Instance exists alt Automation Composition Instance administrative state is not LOCKED ACM_Runtime -> REST: Automation Composition instance exists and is not LOCKED else ACM_Runtime -> REST: Automation Composition instance does not exist end else ACM_Runtime -> Participants: [ASYNC] Undeploy AC Element Instances for this AC Instance ACM_Runtime -> ACM_Database: Mark this AC Instance and its AC Element Instances as UndeployingUNDEPLOYING ACM_Runtime -> REST: Undeployment of Automation Composition Instance has been requested end @enduml |
...
PlantUML Macro |
---|
@startuml participant ACM_Runtime participant Participant participant Participant_API ACM_Runtime -> Participant: [ASYNC] Undeploy AC Element Instances for this AC Instance loop over AC Element Instances in AC Instance alt Does the primed Participant ID on this AC Element Instance\nmatch my Participant ID? alt Does this AC Element Instance exist? ACM_Runtime <- Participant: [ASYNC] WARN: AC Element does not exist else Is this administrative state of this AC Element Instance LOCKED Participant -> Participant_API: Undeploy AC Element Instance activate Participant_API Participant <- Participant_API: Undeploy AC Element Instance Response deactivate Participant_API alt AC Element undeployed successfully ACM_Runtime <- Participant: [ASYNC] INFO: AC Element undeployed successfully else note ACM_Runtime <-left of Participant: [ASYNC] ERROR: AC ElementUndeploy wasalways notreturns undeployedsuccess end note else ACM_Runtime <- Participant: [ASYNC] WARN: AC Element is already undeployed end else note left of Participant Ignore this AC Element instance as its for another participant end note end end @enduml |
...
PlantUML Macro |
---|
@startuml participant ACM_Runtime participant Participant database ACM_Database ACM_Runtime <- Participant: [ASYNC] Undeploy Automation Composition Element Instance Response ACM_Runtime -> ACM_Database: Store Automation Composition Element Instance Response Information alt Is AC Element Instance undeployed? ACM_Runtime -> ACM_Database: Mark AC Element Instance as UNDEPLOYED alt Are all the other AC Element Instances in this AC Instance in state UNDEPLOYED? ACM_Runtime -> ACM_Runtime: Set AC Instance state as UNDEPLOYED Undeployed end end @enduml |
3.5 Read Automation Composition Instances
...