stable
Clone or download
Close request #29278: Let the FTS backends deal with the transformation of the usual content format
This moves the conversion of usual content formats (HTML, CommonMark and plaintext) to the FTS backends themselves. This present multiple advantages: * it avoids CPu cycles if there is no FTS backends actived or usable * it moves the conversion into the async code which can improve the experience for the user when updating items * it lays the groundwork for expanding the usage of the FTS outside of the tracker plugin, having a common way to manage the usual content will reduce the code duplication between the different plugins * it also does not assume the capabilities of the FTS backends, some might have the capability deal with it directly (e.g. Elastic can strip HTML tags when indexing documents) No functional changes expected. Note that the step definition fields are still pre-processed into plaintext due to their unusual format. They are unique in the sense that for a same item to index we might have multiple formats. Change-Id: I493ed0337d76d75c422eb6310d323ec7cf10b23b
Modified Files
Name | ||||
---|---|---|---|---|
M | plugins/fts_common/include/Index/Asynchronous/IndexItemTask.php | +3 | −2 | Go to diff View file |
A | plugins/fts_common/include/Index/InsertPlaintextItemsIntoIndex.php | +28 | −0 | Go to diff View file |
A | plugins/fts_common/include/Index/ItemToIndexPlaintextTransformer.php | +56 | −0 | Go to diff View file |
M | plugins/fts_common/include/Index/NullIndexHandler.php | +2 | −2 | Go to diff View file |
A | plugins/fts_common/include/Index/PlaintextItemToIndex.php | +40 | −0 | Go to diff View file |
M | plugins/fts_common/tests/unit/Index/Asynchronous/IndexItemTaskTest.php | +4 | −4 | Go to diff View file |
M | plugins/fts_common/tests/unit/Index/Asynchronous/IndexingWorkerEventDispatcherTest.php | +1 | −1 | Go to diff View file |
M | plugins/fts_common/tests/unit/Index/InsertItemsIntoIndexMetricCollectorTest.php | +2 | −2 | Go to diff View file |
M | plugins/fts_common/tests/unit/Index/ItemToIndexLimitedBatchQueueTest.php | +3 | −3 | Go to diff View file |
A | plugins/fts_common/tests/unit/Index/ItemToIndexPlaintextTransformerTest.php | +82 | −0 | Go to diff View file |
M | plugins/fts_db/include/Index/SearchDAO.php | +7 | −7 | Go to diff View file |
M | plugins/fts_db/include/fts_dbPlugin.php | +9 | −1 | Go to diff View file |
M | plugins/fts_db/tests/integration/Index/SearchDAOTest.php | +13 | −13 | Go to diff View file |
M | plugins/fts_meilisearch/include/Index/MeilisearchHandler.php | +5 | −5 | Go to diff View file |
M | plugins/fts_meilisearch/include/Index/MeilisearchMetadataDAO.php | +4 | −4 | Go to diff View file |
M | plugins/fts_meilisearch/include/fts_meilisearchPlugin.php | +6 | −1 | Go to diff View file |
M | plugins/fts_meilisearch/tests/integration/Index/MeilisearchMetadataDAOTest.php | +7 | −7 | Go to diff View file |
M | plugins/fts_meilisearch/tests/unit/Index/MeilisearchHandlerTest.php | +5 | −5 | Go to diff View file |
M | plugins/testmanagement/include/TestManagement/Step/Definition/Field/StepDefinition.php | +2 | −0 | Go to diff View file |
M | plugins/tracker/include/Tracker/Artifact/Changeset/Comment/ChangesetCommentIndexer.php | +5 | −3 | Go to diff View file |
M | plugins/tracker/include/Tracker/Artifact/Tracker_Artifact_Changeset_Comment.class.php | +1 | −1 | Go to diff View file |
M | plugins/tracker/include/Tracker/FormElement/FieldContentIndexer.php | +5 | −1 | Go to diff View file |
M | plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_String.php | +2 | −1 | Go to diff View file |
M | plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_Text.php | +3 | −4 | Go to diff View file |
M | plugins/tracker/tests/unit/Artifact/Changeset/Comment/ChangesetCommentIndexerTest.php | +2 | −0 | Go to diff View file |
M | plugins/tracker/tests/unit/Tracker/FormElement/FieldContentIndexerTest.php | +3 | −1 | Go to diff View file |
M | src/common/Search/ItemToIndex.php | +7 | −0 | Go to diff View file |
M | tests/unit/common/Search/ItemToIndexQueueEventBasedTest.php | +1 | −1 | Go to diff View file |