Uploaded image for project: 'jBPM'
  1. jBPM
  2. JBPM-4227

Make HumanTask transaction interceptor thread safe

XMLWordPrintable

      TaskService is since version 6 command based and internally uses JPA as storage, by that it utilizes task transaction interceptor to manage transactions and persistence context. It follows the same design as singleSessionCommandService and thus should be synchronized to protect the JpaPersistenceContextManager state.
      Currently it is not synchronized which might lead to concurrent requests modifying the state of JpaPersistenceContextManager which in turn can lead to optimistic lock exceptions and other unexpected issues.

      Making it thread safe will have impact on performance in case single instance of task service is used. So that will require bit of rethink for usage task service in shared environments such as CDI.

            swiderski.maciej Maciej Swiderski (Inactive)
            swiderski.maciej Maciej Swiderski (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: