2017-10-14 13:02:48 +02:00
.. _configuration_options_index:
Indexing
========
Holds settings regarding the indexing, e.g. of TYPO3 records, to search services.
Configured as::
plugin {
tx_searchcore {
settings {
indexing {
identifier {
indexer = FullyQualifiedClassname
// the settings
}
}
}
}
}
Where `` identifier `` is up to you, but should match table names to make :ref: `TcaIndexer` work.
The following settings are available. For each setting its documented which indexer consumes it.
.. _rootLineBlacklist:
rootLineBlacklist
-----------------
2017-10-29 12:25:25 +01:00
Used by: :ref: `TcaIndexer` , :ref: `PagesIndexer` .
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Defines a blacklist of page uids. Records below any of these pages, or subpages, are not
indexed. This allows you to define areas that should not be indexed.
The page attribute *No Search* is also taken into account to prevent indexing records from only one
page without recursion.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Contains a comma separated list of page uids. Spaces are trimmed.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Example::
2017-10-14 13:02:48 +02:00
2018-03-08 08:17:41 +01:00
plugin.tx_searchcore.settings.indexing.pages.rootLineBlacklist = 3, 10, 100
2017-10-14 13:02:48 +02:00
.. _additionalWhereClause:
additionalWhereClause
---------------------
2017-10-29 12:25:25 +01:00
Used by: :ref: `TcaIndexer` , :ref: `PagesIndexer` .
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Add additional SQL to where clauses to determine indexable records from the table. This way you
can exclude specific records like `` tt_content `` records with specific `` CType `` values or
2018-03-08 08:17:41 +01:00
something else.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Example::
2017-10-14 13:02:48 +02:00
2018-03-08 08:17:41 +01:00
plugin.tx_searchcore.settings.indexing.tt_content.additionalWhereClause = tt_content.CType NOT IN ('gridelements_pi1', 'list', 'div', 'menu')
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
.. attention ::
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Make sure to prefix all fields with the corresponding table name. The selection from
2018-03-08 08:17:41 +01:00
database might contain joins and can lead to SQL errors if a field exists in multiple tables.
2017-10-14 13:02:48 +02:00
.. _abstractFields:
abstractFields
--------------
2017-10-29 12:25:25 +01:00
Used by: :ref: `PagesIndexer` .
2017-10-14 13:02:48 +02:00
2018-03-08 08:17:41 +01:00
.. note ::
Will be migrated to :ref: `dataprocessors` in the future.
2017-10-29 12:25:25 +01:00
Define which field should be used to provide the auto generated field "search_abstract".
The fields have to exist in the record to be indexed. Therefore fields like `` content `` are also
possible.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Example::
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
# As last fallback we use the content of the page
2018-03-08 08:17:41 +01:00
plugin.tx_searchcore.settings.indexing.pages.abstractFields := addToList(content)
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Default::
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
abstract, description, bodytext
2017-10-14 13:02:48 +02:00
2018-03-15 08:29:44 +01:00
.. _contentFields:
contentFields
-------------
Used by: :ref: `PagesIndexer` .
Define which fields should be used to provide the auto generated field "content".
Example::
plugin.tx_searchcore.settings.indexing.pages.contentFields := addToList(table_caption)
Default::
header, bodytext
2017-10-14 13:02:48 +02:00
.. _mapping:
mapping
-------
2018-03-08 08:17:41 +01:00
Used by: :ref: `connection_elasticsearch` connection while indexing.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Define mapping for Elasticsearch, have a look at the official docs: https://www.elastic.co/guide/en/elasticsearch/reference/5.2/mapping.html
2018-03-08 08:17:41 +01:00
You are able to define the mapping for each property / column.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Example::
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
plugin.tx_searchcore.settings.indexing.tt_content.mapping {
CType {
type = keyword
2017-10-14 13:02:48 +02:00
}
2017-10-29 12:25:25 +01:00
}
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
The above example will define the `` CType `` field of `` tt_content `` as `` type: keyword `` . This
makes building a facet possible.
2017-10-14 13:02:48 +02:00
.. _index:
index
-----
2018-03-08 08:17:41 +01:00
Used by: :ref: `connection_elasticsearch` connection while indexing.
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Define index for Elasticsearch, have a look at the official docs: https://www.elastic.co/guide/en/elasticsearch/reference/5.2/indices-create-index.html
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
Example::
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
plugin.tx_searchcore.settings.indexing.tt_content.index {
analysis {
analyzer {
ngram4 {
type = custom
tokenizer = ngram4
char_filter = html_strip
filter = lowercase, asciifolding
2017-10-14 13:02:48 +02:00
}
2017-10-29 12:25:25 +01:00
}
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
tokenizer {
ngram4 {
type = ngram
min_gram = 4
max_gram = 4
2017-10-14 13:02:48 +02:00
}
}
}
2017-10-29 12:25:25 +01:00
}
2017-10-14 13:02:48 +02:00
2017-10-29 12:25:25 +01:00
`` char_filter `` and `` filter `` are a comma separated list of options.
2017-10-14 13:02:48 +02:00
2018-03-08 08:17:41 +01:00
.. _indexing_dataProcessing:
2017-10-14 13:02:48 +02:00
dataProcessing
--------------
2018-03-06 10:47:14 +01:00
Used by: All connections while indexing, due to implementation inside `` AbstractIndexer `` .
2017-10-14 13:02:48 +02:00
2018-03-08 08:17:41 +01:00
Configure modifications on each document before sending it to the configured connection.
For full documentation check out :ref: `dataprocessors` .