This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

ARS add/remove member workflow only triggers on first item added/removed when multiple processed

I have a workflow that sets or clears an attribute for members added or removed from a group.  It works great if you are adding or removing 1 member at a time.  However if you add or remove 2 or more in the same transaction, only 1 item is processed by the workflow.  Is this a bug?

  • I just assisted a customer with configuring this.

    There is an issue with targeting the Added Member in the Update Activity. You can't get a clean reference. The workaround is to trigger a search activity and target the found objects instead.

    The Workflow looks like this:

    The Search looks like this:

    The conditional in the first If/Else Branch looks like this:

    And the Update activity targets the object returned by the search result:

    It's a little complicated, but it works. I have engaged the Product Team to allow for something much simpler and to prevent the defect which you encountered.

  • Thank you for this, it works great for the ADD member but I still need to clear the attribute when a member is removed.  I will see if it can use this logic somehow to do the remove.

  • Just copy the Workflow and change the trigger and the search.

    The new Search will look something like this:

    Ideally, you should have a filter here so that you return only  a subset of users in Active Directory. Adding a filter for the expected value of the attribute which you want to clear should do the trick.

  • Here is how it ended up working around this issue.  For the add to the group, I used the suggestion from Terrance in his first reply.  Worked great.  I ended up using a scheduled workflow for the removal.  I could not get it to work real time like for the add to group.  The scheduled workflow does a search to find the objects with the attribute set.  It then uses and if/else to see if the object is a member of the group.  If it is no longer a member, it clears the attribute else it skips it.

    It would be great if this could be corrected in future releases.

  • Sorry, I forgot to mention, the Search activity has a hidden default. It only returns 100 objects and then terminates. You'll have to disable that in the second Workflow. It's under the Additional Settings at the bottom.

    You might also want to leave the Automation Workflow as a redundancy option.

  • I did set the search to have no limit, I've done other searches so I knew it was there. Thank you for taking the time to assist with this.

  • I missed something else in the Removal Workflow, my apologies.

    The If/Else Branch needs to be updated with the following conditional test: