<case xmlns="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:c="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:icfs="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/resource-schema-3" xmlns:org="http://midpoint.evolveum.com/xml/ns/public/common/org-3" xmlns:q="http://prism.evolveum.com/xml/ns/public/query-3" xmlns:ri="http://midpoint.evolveum.com/xml/ns/public/resource/instance-3" xmlns:t="http://prism.evolveum.com/xml/ns/public/types-3" oid="0d7b204a-0fdf-4f27-bf3e-fb12f0ca1b7f" version="0">
<name>Approving and executing change of user "jack" (started 28-Feb-2019 18:40:11)</name>
<metadata>
<createTimestamp>2019-02-28T18:40:11.797+01:00</createTimestamp>
</metadata>
<localizableName xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:SingleLocalizableMessageType">
<key>ApprovingAndExecuting.ChangeOf</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectSpecification</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectTypeLowercase.UserType</key>
<fallbackMessage>UserType</fallbackMessage>
</localizable>
</argument>
<argument>
<value>jack</value>
</argument>
</localizable>
</argument>
<argument>
<value>28-Feb-2019 18:40:11</value>
</argument>
</localizableName>
<objectRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType">
<!-- jack -->
</objectRef>
<requestorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType">
<!-- administrator -->
</requestorRef>
<workflowContext/>
<modelContext>
<state>primary</state>
<focusContext>
<objectOldRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType">
<!-- jack -->
</objectOldRef>
<objectNewRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType">
<!-- jack -->
</objectNewRef>
<objectTypeClass>com.evolveum.midpoint.xml.ns._public.common.common_3.UserType</objectTypeClass>
<oid>c0c010c0-d34d-b33f-f00d-111111111111</oid>
<iteration>0</iteration>
<iterationToken/>
<secondaryDeltas/>
</focusContext>
<focusClass>com.evolveum.midpoint.xml.ns._public.common.common_3.UserType</focusClass>
<doReconciliationForAllProjections>false</doReconciliationForAllProjections>
<executionPhaseOnly>false</executionPhaseOnly>
<projectionWave>1</projectionWave>
<executionWave>0</executionWave>
<lazyAuditRequest>false</lazyAuditRequest>
<requestAudited>false</requestAudited>
<executionAudited>false</executionAudited>
<requestAuthorized>true</requestAuthorized>
<stats/>
<requestMetadata>
<requestTimestamp>2019-02-28T18:40:11.648+01:00</requestTimestamp>
<requestorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType">
<!-- administrator -->
</requestorRef>
</requestMetadata>
</modelContext>
</case>
New approvals - sample data structures
Example 1: Approving assignment of Role1 to jack
After request arrives and approval process is set up
Root case
Child case: approving the role assignment
<case xmlns="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:c="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:icfs="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/resource-schema-3" xmlns:org="http://midpoint.evolveum.com/xml/ns/public/common/org-3" xmlns:q="http://prism.evolveum.com/xml/ns/public/query-3" xmlns:ri="http://midpoint.evolveum.com/xml/ns/public/resource/instance-3" xmlns:t="http://prism.evolveum.com/xml/ns/public/types-3" oid="07bba1d8-a471-4086-96af-b1145fe76d12" version="3">
<name>Assigning role "Role1" to user "jack"</name>
<metadata>
<createTimestamp>2019-02-28T18:40:11.773+01:00</createTimestamp>
</metadata>
<localizableName xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:SingleLocalizableMessageType">
<key>DefaultPolicyConstraint.Short.assignmentModification.toBeAdded</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectSpecification</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectTypeLowercase.RoleType</key>
<fallbackMessage>RoleType</fallbackMessage>
</localizable>
</argument>
<argument>
<value>Role1</value>
</argument>
</localizable>
</argument>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectSpecification</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectTypeLowercase.UserType</key>
<fallbackMessage>UserType</fallbackMessage>
</localizable>
</argument>
<argument>
<value>jack</value>
</argument>
</localizable>
</argument>
</localizableName>
<parentRef oid="0d7b204a-0fdf-4f27-bf3e-fb12f0ca1b7f" relation="org:default" type="c:CaseType"/>
<objectRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<targetRef oid="00000001-d34d-b33f-f00d-000000000001" relation="org:default" type="c:RoleType"/>
<requestorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType"/>
<event xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:CaseCreationEventType">
<timestamp>2019-02-28T18:40:11.773+01:00</timestamp>
<initiatorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType">
<targetName>administrator</targetName>
</initiatorRef>
</event>
<workItem id="2">
<name>Assigning role "Role1" to user "jack"</name>
<stageNumber>1</stageNumber>
<createTimestamp>2019-02-28T18:40:11.982+01:00</createTimestamp>
<originalAssigneeRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<assigneeRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
</workItem>
<workflowContext>
<processorSpecificState xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:WfPrimaryChangeProcessorStateType">
<processor>com.evolveum.midpoint.wf.impl.processors.primary.PrimaryChangeProcessor</processor>
<changeAspect>com.evolveum.midpoint.wf.impl.processors.primary.policy.PolicyRuleBasedAspect</changeAspect>
<deltasToProcess>
<focusPrimaryDelta>
<t:changeType>modify</t:changeType>
<t:objectType>c:UserType</t:objectType>
<t:oid>c0c010c0-d34d-b33f-f00d-111111111111</t:oid>
<t:itemDelta>
<t:modificationType>add</t:modificationType>
<t:path>c:assignment</t:path>
<t:value>
<targetRef oid="00000001-d34d-b33f-f00d-000000000001" type="c:RoleType"/>
</t:value>
</t:itemDelta>
</focusPrimaryDelta>
</deltasToProcess>
</processorSpecificState>
<processSpecificState xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:ItemApprovalProcessStateType">
<approvalSchema>
<stage id="1">
<number>1</number>
<approverRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<outcomeIfNoApprovers>reject</outcomeIfNoApprovers>
<groupExpansion>byClaimingWorkItem</groupExpansion>
</stage>
</approvalSchema>
<policyRules/>
</processSpecificState>
</workflowContext>
<stageNumber>1</stageNumber>
</case>
(The root case groups all operations requested at the same time. For each such operation a separate subcase is created.)
After the work item is approved
Root case
<case xmlns="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:c="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:icfs="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/resource-schema-3" xmlns:org="http://midpoint.evolveum.com/xml/ns/public/common/org-3" xmlns:q="http://prism.evolveum.com/xml/ns/public/query-3" xmlns:ri="http://midpoint.evolveum.com/xml/ns/public/resource/instance-3" xmlns:t="http://prism.evolveum.com/xml/ns/public/types-3" oid="0d7b204a-0fdf-4f27-bf3e-fb12f0ca1b7f" version="0">
<name>Approving and executing change of user "jack" (started 28-Feb-2019 18:40:11)</name>
<metadata>
<createTimestamp>2019-02-28T18:40:11.797+01:00</createTimestamp>
</metadata>
<localizableName xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:SingleLocalizableMessageType">
<key>ApprovingAndExecuting.ChangeOf</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectSpecification</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectTypeLowercase.UserType</key>
<fallbackMessage>UserType</fallbackMessage>
</localizable>
</argument>
<argument>
<value>jack</value>
</argument>
</localizable>
</argument>
<argument>
<value>28-Feb-2019 18:40:11</value>
</argument>
</localizableName>
<objectRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<requestorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType"/>
<workflowContext/>
<modelContext>
<state>primary</state>
<focusContext>
<objectOldRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<objectNewRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<objectTypeClass>com.evolveum.midpoint.xml.ns._public.common.common_3.UserType</objectTypeClass>
<oid>c0c010c0-d34d-b33f-f00d-111111111111</oid>
<iteration>0</iteration>
<iterationToken/>
<secondaryDeltas/>
</focusContext>
<focusClass>com.evolveum.midpoint.xml.ns._public.common.common_3.UserType</focusClass>
<doReconciliationForAllProjections>false</doReconciliationForAllProjections>
<executionPhaseOnly>false</executionPhaseOnly>
<projectionWave>1</projectionWave>
<executionWave>0</executionWave>
<lazyAuditRequest>false</lazyAuditRequest>
<requestAudited>false</requestAudited>
<executionAudited>false</executionAudited>
<requestAuthorized>true</requestAuthorized>
<stats/>
<requestMetadata>
<requestTimestamp>2019-02-28T18:40:11.648+01:00</requestTimestamp>
<requestorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType"/>
</requestMetadata>
</modelContext>
</case>
Child case
<case xmlns="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:c="http://midpoint.evolveum.com/xml/ns/public/common/common-3" xmlns:icfs="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/resource-schema-3" xmlns:org="http://midpoint.evolveum.com/xml/ns/public/common/org-3" xmlns:q="http://prism.evolveum.com/xml/ns/public/query-3" xmlns:ri="http://midpoint.evolveum.com/xml/ns/public/resource/instance-3" xmlns:t="http://prism.evolveum.com/xml/ns/public/types-3" oid="07bba1d8-a471-4086-96af-b1145fe76d12" version="8">
<name>Assigning role "Role1" to user "jack"</name>
<metadata>
<createTimestamp>2019-02-28T18:40:11.773+01:00</createTimestamp>
</metadata>
<localizableName xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:SingleLocalizableMessageType">
<key>DefaultPolicyConstraint.Short.assignmentModification.toBeAdded</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectSpecification</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectTypeLowercase.RoleType</key>
<fallbackMessage>RoleType</fallbackMessage>
</localizable>
</argument>
<argument>
<value>Role1</value>
</argument>
</localizable>
</argument>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectSpecification</key>
<argument>
<localizable xsi:type="c:SingleLocalizableMessageType">
<key>ObjectTypeLowercase.UserType</key>
<fallbackMessage>UserType</fallbackMessage>
</localizable>
</argument>
<argument>
<value>jack</value>
</argument>
</localizable>
</argument>
</localizableName>
<parentRef oid="0d7b204a-0fdf-4f27-bf3e-fb12f0ca1b7f" relation="org:default" type="c:CaseType"/>
<objectRef oid="c0c010c0-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<targetRef oid="00000001-d34d-b33f-f00d-000000000001" relation="org:default" type="c:RoleType"/>
<requestorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType"/>
<state>closed</state>
<outcome>http://midpoint.evolveum.com/xml/ns/public/model/approval/outcome#approve</outcome>
<closeTimestamp>2019-02-28T18:40:12.424+01:00</closeTimestamp>
<event xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:CaseCreationEventType">
<timestamp>2019-02-28T18:40:11.773+01:00</timestamp>
<initiatorRef oid="00000000-0000-0000-0000-000000000002" relation="org:default" type="c:UserType">
<targetName>administrator</targetName>
</initiatorRef>
</event>
<event xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:WorkItemCompletionEventType">
<timestamp>2019-02-28T18:40:12.355+01:00</timestamp>
<initiatorRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType">
<targetName>r1boss</targetName>
</initiatorRef>
<stageNumber>1</stageNumber>
<externalWorkItemId>07bba1d8-a471-4086-96af-b1145fe76d12:2</externalWorkItemId>
<originalAssigneeRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<output xsi:type="c:WorkItemResultType">
<outcome>http://midpoint.evolveum.com/xml/ns/public/model/approval/outcome#approve</outcome>
</output>
</event>
<workItem id="2">
<name>Assigning role "Role1" to user "jack"</name>
<stageNumber>1</stageNumber>
<createTimestamp>2019-02-28T18:40:11.982+01:00</createTimestamp>
<originalAssigneeRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<assigneeRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<performerRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<output xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:WorkItemResultType">
<outcome>http://midpoint.evolveum.com/xml/ns/public/model/approval/outcome#approve</outcome>
</output>
<closeTimestamp>2019-02-28T18:40:12.268+01:00</closeTimestamp>
</workItem>
<workflowContext>
<processorSpecificState xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:WfPrimaryChangeProcessorStateType">
<processor>com.evolveum.midpoint.wf.impl.processors.primary.PrimaryChangeProcessor</processor>
<changeAspect>com.evolveum.midpoint.wf.impl.processors.primary.policy.PolicyRuleBasedAspect</changeAspect>
<deltasToProcess>
<focusPrimaryDelta>
<t:changeType>modify</t:changeType>
<t:objectType>c:UserType</t:objectType>
<t:oid>c0c010c0-d34d-b33f-f00d-111111111111</t:oid>
<t:itemDelta>
<t:modificationType>add</t:modificationType>
<t:path>c:assignment</t:path>
<t:value>
<targetRef oid="00000001-d34d-b33f-f00d-000000000001" type="c:RoleType"/>
</t:value>
</t:itemDelta>
</focusPrimaryDelta>
</deltasToProcess>
<resultingDeltas>
<focusPrimaryDelta>
<t:changeType>modify</t:changeType>
<t:objectType>c:UserType</t:objectType>
<t:oid>c0c010c0-d34d-b33f-f00d-111111111111</t:oid>
<t:itemDelta>
<t:modificationType>add</t:modificationType>
<t:path>c:assignment</t:path>
<t:value>
<targetRef oid="00000001-d34d-b33f-f00d-000000000001" type="c:RoleType"/>
</t:value>
</t:itemDelta>
</focusPrimaryDelta>
</resultingDeltas>
</processorSpecificState>
<processSpecificState xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="c:ItemApprovalProcessStateType">
<approvalSchema>
<stage id="1">
<number>1</number>
<approverRef oid="00000000-d34d-b33f-f00d-111111111111" relation="org:default" type="c:UserType"/>
<outcomeIfNoApprovers>reject</outcomeIfNoApprovers>
<groupExpansion>byClaimingWorkItem</groupExpansion>
</stage>
</approvalSchema>
<policyRules/>
</processSpecificState>
</workflowContext>
<stageNumber>1</stageNumber>
</case>
Note we have resultingDeltas property containing what was approved. It is then put into the original model context and executed.
Was this page helpful?
YES
NO
Thanks for your feedback