[midPoint-git] [Evolveum/midpoint] 74806e: Fix a couple of task thread-safety issues

mederly noreply at github.com
Wed Mar 31 15:33:22 CEST 2021


  Branch: refs/heads/master
  Home:   https://github.com/Evolveum/midpoint
  Commit: 74806ee5a1f5bc3deea4734beec25a0563000384
      https://github.com/Evolveum/midpoint/commit/74806ee5a1f5bc3deea4734beec25a0563000384
  Author: Pavol Mederly <mederly at evolveum.com>
  Date:   2021-03-31 (Wed, 31 Mar 2021)

  Changed paths:
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/web/page/admin/roles/AbstractRoleMemberPanel.java
    M model/model-impl/src/main/java/com/evolveum/midpoint/model/impl/lens/projector/focus/AssignmentTripleEvaluator.java
    M model/model-impl/src/main/java/com/evolveum/midpoint/model/impl/scripting/VariablesUtil.java
    M model/model-test/src/main/java/com/evolveum/midpoint/model/test/AbstractModelIntegrationTest.java
    M model/report-impl/src/main/java/com/evolveum/midpoint/report/impl/ReportJasperCreateTaskHandler.java
    M model/report-impl/src/main/java/com/evolveum/midpoint/report/impl/ReportTaskHandler.java
    M repo/task-api/src/main/java/com/evolveum/midpoint/task/api/Task.java
    M repo/task-api/src/main/java/com/evolveum/midpoint/task/api/test/NullTaskImpl.java
    M repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/LightweightTaskManager.java
    M repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/TaskQuartzImpl.java
    M repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/tasks/TaskPersister.java
    M repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/tasks/TaskRetriever.java
    M repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/tracing/TracingOutputCreator.java
    M repo/task-quartz-impl/src/test/java/com/evolveum/midpoint/task/quartzimpl/MockParallelTaskHandler.java
    M repo/task-quartz-impl/src/test/java/com/evolveum/midpoint/task/quartzimpl/TestTaskManagerBasic.java

  Log Message:
  -----------
  Fix a couple of task thread-safety issues

1) OperationResult is not a thread-safe structure, yet it was
exposed to multiple threads - mainly in getUpdatedOrClonedTaskObject
method.

2) Even backing task prism objects were exposed to multiple threads
in a special case: When a task with running LATs was fetched (with an
option to retrieve also subtasks), live instances of prism objects
were returned. If they were later processed - e.g. serialized in GUI
- concurrency-related exceptions could occur.

All of this should be now fixed, along with better naming for methods
that give access to backing task prism object.

A price to pay is that the operation result in returned objects
is not updated in these cases. But it should be acceptable.

This should resolve MID-6910.


  Commit: 8051016f3a37da226a684647ac1cb0d1f4cc5550
      https://github.com/Evolveum/midpoint/commit/8051016f3a37da226a684647ac1cb0d1f4cc5550
  Author: Pavol Mederly <mederly at evolveum.com>
  Date:   2021-03-31 (Wed, 31 Mar 2021)

  Changed paths:
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/gui/api/component/autocomplete/ReferenceConverter.java
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/gui/api/util/WebComponentUtil.java
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/gui/impl/component/ContainerableListPanel.java
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/gui/impl/factory/panel/SearchFilterTypeForQueryModel.java
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/web/component/search/ReferenceValueSearchPanel.java
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/web/component/search/ReferenceValueSearchPopupPanel.java
    M gui/admin-gui/src/main/java/com/evolveum/midpoint/web/page/admin/server/OperationalButtonsPanel.html
    M repo/repo-sqlbase/src/main/java/com/evolveum/midpoint/repo/sqlbase/mapping/item/ItemSqlMapper.java

  Log Message:
  -----------
  Merge remote-tracking branch 'origin/master'


Compare: https://github.com/Evolveum/midpoint/compare/65e3911a2bde...8051016f3a37


More information about the midPoint-svn mailing list