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

Decide on equality of PCVs (also PRVs)

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: backlog
    • Component/s: Prism
    • Labels:
      None
    • Subscription:
      Internal

      Description

      Decide on how to decide if two PCVs are equal, e.g. for the reasons of

      1. calling item.remove(value) e.g. when applying an item delta with a "delete" part,
      2. comparing PCs,
      3. computing diff for two PCs,
      4. deleting values from item delta.

      Current approach is not well defined. For example, item.remove(value) consider two PCVs equal if

      1. either they "represent the same value" - i.e. they have the same IDs, or in lax mode, at least one is single-valued,
      2. or they "have the same real value" (equalsRealValue) - i.e. their content is the same, irrespective of IDs and operational items
        This caused problems recently because wrong triggers got deleted (see TestParseDiffPatch.testCampaign). Solution was to set trigger timestamp to be NOT operational. See https://github.com/Evolveum/midpoint/commit/9556eccae0149e050e22183e4ff020c05100a0b4.

      Other places might treat this a bit differently. We have to unify this. Search for the ID of this issue in the source code.

      (For PRVs, situation is also interesting: representSameValue means OID + relation equality, which is also to be discussed.)

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                Created:
                Updated: