Custom User Provisioning executes after every login

0
I set a microflow to execute in the SAML "custom logic for user provisioning" section as seen below.It executes just fine. The problem is, it executes every subsequent time ANY existnig user logs in. I only want it to execute when PROVISIONING, not when logging in. Why is it doing this? And if it is going to execute every login, why have a seperate "after sign in logic" section if the custom user provisioning microflow ALREADY executes on every login?
asked
1 answers
1

Hi Brian Lorraine


Despite the name "user provisioning", the SAML module initiates every login from the SP side, exchanging messages using the same RequestID and RelayState. The custom logic for user provisioning microflow is called every single login not just on first-time user creation. Mendix uses it to Create the user if they don't exist OR sync/update the user if they already exist (role sync, attribute updates, etc.).So it's really a user sync on every login microflow, not a one-time provisioning hook.


Then why we have two separate? it is very simple


Custom user provisioning:-Every login handles create/update of the User object and Attribute mapping, role assignment from SAML claims


After sign in logic:-Every login runs after session is established and mainly used for Navigation, logging, business logic that needs a live session.


I hope it is clear.

answered