Table of Contents

Deduplication for automatic roles by organization

The feature is very usefull for CzechIdM environment that has defined many same automatic roles by organization strcuture. For example:

In this case exists organization structure with three levels. In last three level automatic roles are defined. Automatic roles are defined for same role.

The long running task for deduplication process each level, organization node and their automatic roles. Every automatic role for organization node will be compared with another automatic roles in same level and then build new virtual organization structure with new automatic role definitions.

In our case new organization structure with automatic role definitions will be looked like the second image:

The role role1 was moved on root node. Every node on third level has same automatic role definition and every node has assigned some contracts. On the second level doesn't exist automatic role definiton or assiged contract so role can be moved one more level up = root node.

How works automatic role comparsion

Two automatic role definitons are same when meet together every rules below:

When all these rules are meet the automatic role can be moved up.

These rules must meet for every automatic role on same level.

How can I run deduplication

Deduplication is implemented as long running task. You must go to Settings → Task scheduler → Scheduled tasks and in the agenda just plan new long running task with name Deduplication of automatic roles by tree structure (AutomaticRoleByTreeNodeDeduplicationExecutor).

The long running task has these configurations:

Exception for recursion DOWN and NO

We have this situation:

Same role is assigned on same organization level. But for right side exits third level, for left side is organization node the leaf.

In this case recursion isn't same DOWN and NO (see arrow and dot). But for recursion NO doesn't exist child nodes.

The result will be that role will be marked as same. And role will be moved up.

What the user audit will look like

After new virtual organization structure will be composed task will execute standard events for create and delete automatic role by organization structure (synchronously in this order create → delete).

Task is defensive = for every removed role for user must be added new one.

New role will be added first by task ProcessAutomaticRoleByTreeTaskExecutor and after each new role will be created then duplicit role will be removed by task RemoveAutomaticRoleTaskExecutor.

Know issues