<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hey Oliver,<div class=""><br class=""></div><div class="">I would try adding assignmentProperties in your assignmentTargetSearch to allow a clear set of what can be removed.</div><div class=""><br class=""></div><div class="">...</div><div class="">    <assignmentProperties></div><div class=""><span class="Apple-tab-span" style="white-space:pre"> </span><subtype>hrFeed</subtype></div><div class="">    </assignmentProperties></div><div class=""></assignmentTargetSearch></div><div class=""><br class=""></div><div class="">...</div><div class=""><br class=""></div><div class=""><set></div><div class=""><div class=""><span class="Apple-tab-span" style="white-space:pre"> </span><condition></div><div class=""><span class="Apple-tab-span" style="white-space:pre">         </span><script></div><div class=""><span class="Apple-tab-span" style="white-space:pre">                    </span><code></div><div class=""><span class="Apple-tab-span" style="white-space:pre">                              </span>return input.subtype.contains("hrFeed")</div><div class=""><span class="Apple-tab-span" style="white-space:pre">         </span> <span class="Apple-tab-span" style="white-space:pre">      </span></code></div><div class=""><span class="Apple-tab-span" style="white-space:pre">             </span></script></div><div class=""><span class="Apple-tab-span" style="white-space:pre">   </span></condition></div></div><div class=""></set><br class=""><div class="">
<div dir="auto" style="color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class="Apple-interchange-newline"><span style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class=""><b class="">Jonathan Hill</b></span><br style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Exclamation Labs</span><br style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">300 Washington Street</span><br style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Cumberland, MD  21502</span><br style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><a href="mailto:jhill@exclamationlabs.com" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">jhill@exclamationlabs.com</a><br style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><a href="http://www.exclamationlabs.com" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-variant-position: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">www.exclamationlabs.com</a></div>
</div>
<div><br class=""><blockquote type="cite" class=""><div class="">On Oct 20, 2021, at 10:29 AM, Oliver Schonefeld via midPoint <<a href="mailto:midpoint@lists.evolveum.com" class="">midpoint@lists.evolveum.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Hello,<br class=""><br class="">I am running midPoint 4.3.1 and am trying to automatically assign and unassign organizational units to user accounts. I have modelled the organizational structure of our institute in midpoint. Organizational unit membership is governed by a HR feed (modeled as CVS resource) and user accounts should be assigned or unassigned to org units depending on the information of the hr feed.<br class=""><br class="">I've manged to get the initial assignment of org units to work by adding an inbound mapping to the schema handling section of the HR csv resource:<br class="">  <!-- ... --><br class="">  <inbound><br class="">    <authoritative>true</authoritative><br class="">    <expression><br class="">      <assignmentTargetSearch><br class="">        <targetType>OrgType</targetType><br class="">        <filter><br class="">          <q:equal><br class="">            <q:path>identifier</q:path><br class="">            <expression><br class="">              <path>$input</path><br class="">            </expression><br class="">          </q:equal><br class="">        </filter><br class="">      </assignmentTargetSearch><br class="">    </expression><br class="">    <target><br class="">      <path>assignment</path><br class="">    </target><br class="">  </inbound><br class="">  <!-- ... --><br class=""><br class="">However, if I move a user in my HR feed to another org unit, the new unit gets assigned to the user (e.g. in reconciliation or live sync), but the old unit is never unassigned.<br class=""><br class="">If I set<br class="">  <set><br class="">    <predefined>all</predefined><br class="">  </set><br class="">in <target>, midPoint correctly sets the org units, but also removed all other assignments, e.g. manual requested or auto-assigned roles, etc.<br class=""><br class="">Ideally, I'd like midpoint to only touch the org unit assignments when something changes in the HR feed.<br class=""><br class="">Has anybody some ideas or useful insights, how I can accomplish this goal?<br class=""><br class=""><br class="">Thank you and best regards<br class="">  Oliver<br class="">-- <br class="">Oliver Schonefeld<br class="">Leibniz-Institut für Deutsche Sprache, Informationstechnik (IT)<br class="">R5, 6-13, D-68161 Mannheim<br class="">+49-(0)621-1581-168 | <a href="http://www.ids-mannheim.de" class="">http://www.ids-mannheim.de</a><br class="">_______________________________________________<br class="">midPoint mailing list<br class=""><a href="mailto:midPoint@lists.evolveum.com" class="">midPoint@lists.evolveum.com</a><br class="">https://lists.evolveum.com/mailman/listinfo/midpoint<br class=""></div></div></blockquote></div><br class=""></div></body></html>