Healing a component
A heal request targets a component (a resource that is broken) and attempts to return it to an active state.
Before you begin
- You must create the example assembly instance with an assemblyName of
test_1
, as described in Creating an assembly instance. - To heal the component of an assembly, the assembly to which the component belongs must be in an Active state.
About this task
-
You heal assembly instance components by using the Intents API. For more information about this API, see Intents API.
- The orchestration component accepts the request to heal without performing any checks first.
- Heal is a pattern that calls
Stop
,Start
, and thenIntegrity
on the component. - If
Integrity
is successful, then the heal is successful. - The assembly containing the broken component must be in the
active
state to call heal. - The request to heal includes the ID of the component in the assembly instance to be healed.
Procedure
Results
test_1
assembly with a status of
Completed
: {
"id": "2114fd60-60c5-4ad3-98ef-fd0097044d45",
"assemblyId": "c177f293-6072-4f3c-a544-00347cedf897",
"assemblyName": "test_1",
"assemblyType": "assembly::dummy::1.0",
"lifecycleAction": "Heal",
"intent": {
"assemblyName": "test_1",
"brokenComponentId": "183b0c52-f6cd-474c-8ad3-afdf95ed26c6"
},
"intentType": "HealAssembly",
"status": "Completed",
"startTime": "2022-07-15T14:06:14.775173Z",
"endTime": "2022-07-15T14:06:17.294087Z",
"context": {
"tracectx.transactionid": "91b41695-c7b8-474f-8318-824b98eb70f7",
"componentId": "183b0c52-f6cd-474c-8ad3-afdf95ed26c6"
},
"previousInstance": {...},
"desiredInstance": {...}
}