Project

General

Profile

Actions

Defect #2495

closed

Duplicit automatic roles given by two events and asynchronous role request in same time

Added by Ondřej Kopr over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Radek Tomiška
Category:
Automatic roles
Target version:
Start date:
09/17/2020
Due date:
% Done:

100%

Estimated time:
Affected versions:
Owner:

Description

Use case:
  • project has automatic role for contract EAV,
  • project twice saved EAV contract value for same owner,
  • saving creates two events,
  • each event recalculate automatic roles and decides that new automatic role must be assigned,
  • recalculation creates role request,
  • role request doesn't check or recalculate again automatic role so result is that identity will has two same automatic roles.

LRT ProcessAllAutomaticRoleByAttributeTaskExecutor end with error:

org.springframework.dao.DataIntegrityViolationException: could not extract ResultSet; SQL [n/a]; nested exception is org.hibernate.exception.DataException: could not extract ResultSet

Caused by: org.postgresql.util.PSQLException: ERROR: more than one row returned by a subquery used as an expression

Workaround: not exists


Related issues

Related to IdStory Identity Manager - Defect #2404: Provisioning operations from event and sync. created at the same time can be executed in wrong orderClosedRadek Tomiška07/27/2020

Actions
Related to IdStory Identity Manager - Defect #2605: Automatic role by attribute generates duplicate role requests and assignes subroles directlyClosedRadek Tomiška12/09/2020

Actions
Actions #1

Updated by Ondřej Kopr over 3 years ago

  • Assignee changed from Ondřej Kopr to Radek Tomiška
Actions #3

Updated by Radek Tomiška over 3 years ago

  • Status changed from New to In Progress
  • Target version set to 10.6.0
Actions #4

Updated by Radek Tomiška over 3 years ago

  • Related to Defect #2404: Provisioning operations from event and sync. created at the same time can be executed in wrong order added
Actions #5

Updated by Radek Tomiška over 3 years ago

  • Affected versions deleted (10.4.0, 10.4.1, 10.4.2, 10.4.3)

This issue can occur in all IdM versions (event for synchronous processing), when two changes (e.g. by UI under different logged user) are executed simultaneously on one identity - but probability was really low till #2404 was implemented.

Actions #6

Updated by Radek Tomiška over 3 years ago

  • Target version changed from 10.6.0 to 10.4.7
Actions #7

Updated by Radek Tomiška over 3 years ago

  • Status changed from In Progress to Needs feedback
  • Assignee changed from Radek Tomiška to Vít Švanda
  • % Done changed from 0 to 90

Fixed thx to asynchronous role requests - duplicate concepts for automatic roles are canceled.

Commit:
https://github.com/bcvsolutions/CzechIdMng/commit/89395e1702b7c5d36b3b8a0e4d627d58e4b71515

Could you provide me a feedback, please?

Actions #8

Updated by Vít Švanda over 3 years ago

  • Status changed from Needs feedback to Resolved
  • Assignee changed from Vít Švanda to Radek Tomiška
  • % Done changed from 90 to 100

I did reivew and tested it. Looks good to me.

Actions #9

Updated by Radek Tomiška over 3 years ago

  • Status changed from Resolved to Closed
Actions #10

Updated by Radek Tomiška over 3 years ago

  • Related to Defect #2605: Automatic role by attribute generates duplicate role requests and assignes subroles directly added
Actions

Also available in: Atom PDF