•  
      request #37200 Fulltext indexation in error due to transaction
    Infos
    #37200
    Nicolas Terray (nterray)
    2024-03-13 14:51
    2024-03-08 09:29
    38820
    Details
    Fulltext indexation in error due to transaction

    Following the work that has been done for request #36805, the following error occurs when indexing items:

    2024-03-06T16:59:00+01:00 [356] [info] Index item plugin_artifact_changeset_comment (array (
      'changeset_id' => '154',
      'artifact_id' => '111',
      'tracker_id' => '36',
    ))
    2024-03-06T16:59:00+01:00 [356] [error] Unable to enqueue in tuleap.fts.index-item: You should not start something that will be processed in a different context while being in a transaction (RuntimeException): You should not start something that will be processed in a different context while being in a transaction:
    #0 /usr/share/tuleap/src/common/Queue/PersistentQueueNoTransactionWrapper.php(37): Tuleap\DB\ThereIsAnOngoingTransactionChecker->checkNoOngoingTransaction()
    #1 /usr/share/tuleap/src/common/Queue/EnqueueTask.php(48): Tuleap\Queue\PersistentQueueNoTransactionWrapper->pushSinglePersistentMessage()
    #2 /usr/share/tuleap/plugins/fts_common/include/FullTextSearchBackendPlugin.php(76): Tuleap\Queue\EnqueueTask->enqueue()
    #3 /usr/share/tuleap/src/common/Event/EventManager.class.php(128): Tuleap\FullTextSearchCommon\FullTextSearchBackendPlugin->indexItem()
    #4 /usr/share/tuleap/src/common/Plugin/PluginLoader.php(72): EventManager->eventManagerDispatch()
    #5 /usr/share/tuleap/src/common/Event/EventManager.class.php(117): Tuleap\Plugin\PluginLoader->Tuleap\Plugin\{closure}()
    #6 /usr/share/tuleap/src/common/Event/EventManager.class.php(147): EventManager->processEventOnListener()
    #7 /usr/share/tuleap/src/common/Search/ItemToIndexQueueEventBased.php(35): EventManager->dispatch()
    #8 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/Changeset/Comment/ChangesetCommentIndexer.php(73): Tuleap\Search\ItemToIndexQueueEventBased->addItemToQueue()
    #9 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/Changeset/Comment/ChangesetCommentIndexer.php(61): Tuleap\Tracker\Artifact\Changeset\Comment\ChangesetCommentIndexer->indexComment()
    #10 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/Changeset/Comment/CommentCreator.php(80): Tuleap\Tracker\Artifact\Changeset\Comment\ChangesetCommentIndexer->indexNewChangesetComment()
    #11 /usr/share/tuleap/src/common/NeverThrow/Ok.php(90): Tuleap\Tracker\Artifact\Changeset\Comment\CommentCreator->Tuleap\Tracker\Artifact\Changeset\Comment\{closure}()
    #12 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/Changeset/Comment/CommentCreator.php(49): Tuleap\NeverThrow\Ok->match()
    #13 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/Changeset/NewChangesetCreator.php(121): Tuleap\Tracker\Artifact\Changeset\Comment\CommentCreator->createComment()
    #14 /usr/share/tuleap/src/vendor/paragonie/easydb/src/EasyDB.php(1263): Tuleap\Tracker\Artifact\Changeset\NewChangesetCreator->Tuleap\Tracker\Artifact\Changeset\{closure}()
    #15 /usr/share/tuleap/src/common/DB/DBTransactionExecutorWithConnection.php(44): ParagonIE\EasyDB\EasyDB->tryFlatTransaction()
    #16 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/Changeset/NewChangesetCreator.php(71): Tuleap\DB\DBTransactionExecutorWithConnection->execute()
    #17 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/XMLImport.class.php(520): Tuleap\Tracker\Artifact\Changeset\NewChangesetCreator->create()
    #18 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/XMLImport.class.php(406): Tracker_Artifact_XMLImport->importRemainingChangeset()
    #19 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/XMLImport.class.php(338): Tracker_Artifact_XMLImport->importAllChangesetsBySubmitionDate()
    #20 /usr/share/tuleap/plugins/tracker/include/Tracker/Artifact/XMLImport.class.php(227): Tracker_Artifact_XMLImport->importChangesets()
    #21 /usr/share/tuleap/plugins/tracker/include/TrackerXmlImport.class.php(526): Tracker_Artifact_XMLImport->importArtifactChangesFromXML()
    #22 /usr/share/tuleap/plugins/tracker/include/TrackerXmlImport.class.php(318): TrackerXmlImport->importChangesets()
    #23 /usr/share/tuleap/plugins/tracker/include/trackerPlugin.php(1228): TrackerXmlImport->import()
    #24 /usr/share/tuleap/src/common/Event/EventManager.class.php(128): trackerPlugin->import_xml_project()
    #25 /usr/share/tuleap/src/common/Plugin/PluginLoader.php(72): EventManager->eventManagerDispatch()
    #26 /usr/share/tuleap/src/common/Event/EventManager.class.php(117): Tuleap\Plugin\PluginLoader->Tuleap\Plugin\{closure}()
    #27 /usr/share/tuleap/src/common/Event/EventManager.class.php(105): EventManager->processEventOnListener()
    #28 /usr/share/tuleap/src/common/Project/ProjectXMLImporter.class.php(430): EventManager->processEvent()
    #29 /usr/share/tuleap/src/common/Project/ProjectXMLImporter.class.php(277): ProjectXMLImporter->importContent()
    #30 /usr/share/tuleap/src/common/NeverThrow/Ok.php(71): ProjectXMLImporter->{closure}()
    #31 /usr/share/tuleap/src/common/Project/ProjectXMLImporter.class.php(270): Tuleap\NeverThrow\Ok->andThen()
    #32 /usr/share/tuleap/src/common/CLI/Command/ImportProjectXMLCommand.php(186): ProjectXMLImporter->importNewFromArchive()
    #33 /usr/share/tuleap/src/vendor/symfony/console/Command/Command.php(326): Tuleap\CLI\Command\ImportProjectXMLCommand->execute()
    #34 /usr/share/tuleap/src/vendor/symfony/console/Application.php(1078): Symfony\Component\Console\Command\Command->run()
    #35 /usr/share/tuleap/src/vendor/symfony/console/Application.php(324): Symfony\Component\Console\Application->doRunCommand()
    #36 /usr/share/tuleap/src/common/CLI/Application.php(75): Symfony\Component\Console\Application->doRun()
    #37 /usr/share/tuleap/src/vendor/symfony/console/Application.php(175): Tuleap\CLI\Application->doRun()
    #38 /usr/share/tuleap/src/utils/tuleap.php(327): Symfony\Component\Console\Application->run()
    #39 {main}
    
    Full text search
    15.6
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    Empty
    Stage
    Empty
    Closed
    2024-03-13
    Attachments
    Empty
    References

    Follow-ups