Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-19847

Fix GenericThreadedImportTask manipulation of transaction

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 7.10
    • Fix Version/s: 6.0-HF31, 7.10-HF12, 8.3
    • Component/s: Importer
    • Tags:
    • Backlog priority:
      900
    • Sprint:
      nxFG 8.3.6
    • Story Points:
      1

      Description

      GenericThreadedImportTask seems to leak open transactions in case of error: in the run method, a transaction is started with any check and if an error occurs, the transaction is not committed or rollback.

      According to the code below, the transaction will be committed only if there is no exception before:

                  recursiveCreateDocumentFromNode(rootDoc, rootSource);
                  session.save();
                  GenericMultiThreadedImporter.addCreatedDoc(taskId, uploadedFiles);
                  TransactionHelper.commitOrRollbackTransaction();
      

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours
                2h