From 18b320b609e00ec1f61f17825aa0949b783d13f4 Mon Sep 17 00:00:00 2001 From: Philipp Kitzberger Date: Wed, 17 Jan 2024 22:14:10 +0100 Subject: [PATCH] [DOC] Add infos about adding own field processors Update the wrong section on that it's still impossible to extend the field processors Ports: #3939 --- Documentation/Configuration/Reference/TxSolrIndex.rst | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Documentation/Configuration/Reference/TxSolrIndex.rst b/Documentation/Configuration/Reference/TxSolrIndex.rst index e6abc49289..41edb3324e 100644 --- a/Documentation/Configuration/Reference/TxSolrIndex.rst +++ b/Documentation/Configuration/Reference/TxSolrIndex.rst @@ -52,8 +52,7 @@ fieldProcessingInstructions :Since: 1.2 2.0 :Options: timestampToIsoDate, uppercase, pathToHierarchy (2.5-dkd), pageUidToHierarchy (2.5-dkd) -Assigns processing instructions to Solr fields during indexing (Syntax: Solr index field = processing instruction name). Currently it is not possible to extend / add own processing instructions. -Before documents are sent to the Solr server they are processed by the field processor service. Currently you can make a filed's value all uppercase, convert a UNIX timestamp to an ISO date, or transform a path into a hierarchy for hierarchical facets (2.0 only). Currently you can use only one processing instruction at a time. +Assigns processing instructions to Solr fields during indexing (Syntax: Solr index field = processing instruction name). Before documents are sent to the Solr server they are processed by the field processor service. Currently you can make a filed's value all uppercase, convert a UNIX timestamp to an ISO date, or transform a path into a hierarchy for hierarchical facets (2.0 only). Currently you can use only one processing instruction at a time. Example: @@ -65,6 +64,14 @@ Example: endtime = timestampToIsoDate } +Since version 11.5 it is possible to extend / add own processing instructions. + +.. code-block:: php + + $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['solr']['fieldProcessor']['yourFieldProcessor'] = ACustomFieldProcessor::class; + +Custom processors have to implement interface `ApacheSolrForTypo3\Solr\FieldProcessor\FieldProcessor`. + queue -----