Uploaded image for project: 'MidPoint'
  1. MidPoint
  2. MID-3966

Dynamically-evaluated assignments are not processed correctly

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 3.6 (Comenius)
    • Fix Version/s: 4.0
    • Component/s: None
    • Labels:
      None
    • Subscription:
      Internal

      Description

      Having a user like this

      <user oid="b2a3f4ad-ad7b-4691-83d9-34d5ebb50a04"
      	  xmlns="http://midpoint.evolveum.com/xml/ns/public/common/common-3"
      	  xmlns:c="http://midpoint.evolveum.com/xml/ns/public/common/common-3"
      	  xmlns:q="http://prism.evolveum.com/xml/ns/public/query-3"
      	  xmlns:org="http://midpoint.evolveum.com/xml/ns/public/common/org-3">
      
      	<name>cheese</name>
      	<description>The owner of Scumm Bar</description>
      	<assignment id="3">
      		<targetRef type="RoleType" relation="org:approver">
      			<filter>
      				<q:equal>
      					<q:path>name</q:path>
      					<q:value>a-test-1</q:value>
      				</q:equal>
      			        <resolutionTime>run</resolutionTime>
      			</filter>
      		</targetRef>
      	</assignment>
      	<assignment id="4">
      		<targetRef type="RoleType" relation="org:approver">
      			<filter>
      				<q:equal>
      					<q:path>name</q:path>
      					<q:value>a-test-2a</q:value>
      				</q:equal>
      			        <resolutionTime>run</resolutionTime>
      			</filter>
      		</targetRef>
      	</assignment>
      	<assignment id="5">
      		<targetRef type="RoleType" relation="org:approver">
      			<filter>
      				<q:equal>
      					<q:path>name</q:path>
      					<q:value>a-test-2b</q:value>
      				</q:equal>
      			        <resolutionTime>run</resolutionTime>
      			</filter>
      		</targetRef>
      	</assignment>
      	<assignment id="6">
      		<targetRef type="RoleType" relation="org:approver">
      			<filter>
      				<q:equal>
      					<q:path>name</q:path>
      					<q:value>a-test-4</q:value>
      				</q:equal>
      			        <resolutionTime>run</resolutionTime>
      			</filter>
      		</targetRef>
      	</assignment>
      	<fullName>Ignatius Cheese</fullName>
      </user>
      

      when evaluating his assignments, the dynamically-evaluated ones (id 3, 4, 5, 6) are not considered different, and only one of them is evaluated. See SmartAssignmentKey.equalsAssignment. Identifier is ignored (probably correctly), and when comparing references, the filter is ignored.

      Workaround: include description on these assignments (not on targetRef - that is ignored during comparison as well).

      Note: it does not matter if the relation is 'approver' or 'default'.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                mederly Pavol Mederly
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated: