Como otimizar os índices Oak Lucene para reduzir o tempo de indexação
Otimize os índices Oak Lucene usando as propriedades includedPaths e excludedPaths.
Descrição description
Ambiente
- Adobe Experience Manager 6.0 + Oak 1.0.16 ou posterior
- Adobe Experience Manager 6.1 e 6.2
Problema/Sintomas
Otimize os índices AEM Oak Lucene para reduzir o tempo de reindexação.
Resolução resolution
Você pode otimizar os índices Oak Lucene ajustando o oak: QueryIndexDefinition com propriedades como includedPaths, excludedPaths, name e indexPath.
- As propriedades
includedPathseexcludedPathsrestringem quais caminhos o índice percorre ao reindexar e quais caminhos ele escuta para atualizações de índice. - As propriedades
nameeindexPathtornam os logs de índice mais fáceis de entender, pois marcariam as mensagens de log com o caminho ou nome do índice. Por exemplo:
30.01.2017 14:07:12.934 *DEBUG* [ pool-8-thread-2] org.apache.jackrabbit.oak.plugins.index.lucene.LuceneIndexEditor [ damassetlucene( /oak :index /damAssetLucene )] => Indexed 9000 nodes...Etapas para otimizar os índices:
- Vá para http://aem-host:port/crx/de/index.jsp e faça logon como administrador.
- Navegue até
/oak:index. - Adicione as propriedades realçadas abaixo de
[1]aos índices correspondentes. As propriedadesincludedPathseexcludedPathsdevem sermulti-value String (String[ ] ). - Clique em Salvar tudo no CRXDe.
[ 1] /oak:modificações na propriedade do índice
"authorizables" : { "includedPaths" : [ "/home" ] , "reindexCount" : 1, "name" : "authorizables" , "compatVersion" : 2, "reindex" : false , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "async" : "async" , "indexPath" : "/oak:index/authorizables" },"cqPageLucene" : { "includedPaths" : [ "/content" , "/etc" ] , "reindexCount" : 1, "name" : "cq:Page" , "compatVersion" : 2, "reindex" : false , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "async" : "async" , "indexPath" : "/oak:index/cqPageLucene" },"cqTagLucene" : { "reindexCount" : 1, "name" : "cqTag" , "compatVersion" : 2, "reindex" : false , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "excludedPaths" : [ "/var" , "/tmp" , "/etc/replication" , "/etc/workflow/instances" , "/jcr:system" ] , "async" : "async" , "indexPath" : "/oak:index/cqTagLucene" },"damAssetLucene" : { "includedPaths" : [ "/content/dam" ] , "evaluatePathRestrictions" : true , "reindexCount" : 1, "name" : "damassetlucene" , "compatVersion" : 2, "reindex" : false , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "async" : "async" , "indexPath" : "/oak:index/damAssetLucene" },"lucene" : { "reindexCount" : 1, "name" : "lucene" , "reindex" : false , "includePropertyTypes" : [ "String" ] , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "excludedPaths" : [ "/var" , "/tmp" , "/etc/replication" , "/etc/workflow/instances" , "/jcr:system" ] , "async" : "async" , "indexPath" : "/oak:index/lucene" },"ntBaseLucene" : { "reindexCount" : 1, "name" : "tags" , "compatVersion" : 2, "reindex" : false , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "excludedPaths" : [ "/var" , "/tmp" , "/etc/replication" , "/etc/workflow/instances" , "/jcr:system" ] , "async" : "async" , "indexPath" : "/oak:index/ntBaseLucene" },"workflowDataLucene" : { "reindexCount" : 1, "name" : "workflow" , "compatVersion" : 2, "reindex" : false , "type" : "lucene" , "jcr:primaryType" : "oak:QueryIndexDefinition" , "excludedPaths" : [ "/var" , "/tmp" , "/etc/replication" , "/jcr:system" ] , "async" : "async" , "indexPath" : "/oak:index/workflowDataLucene" }recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f