Nivel 1
Nivel 2
Iniciar sesión en la comunidad
Iniciar sesión para ver todas las insignias
I am trying to create custom index on jcr:content/cq:lastReplicationAction on AEM but for some reason it complained about "Not A Valid JCR Name"
Am I missing something here?
¡Resuelto! Ir a solución.
Los temas ayudan a categorizar el contenido de la comunidad e incrementan la posibilidad de encontrar contenido relevante.
Vistas
Respuestas
Total de me gusta
@aemUser2345
For Property Index in OakIndexDefinition,
You need not specify path of the property, just go with all properties in propertyNames field (i.e. cq:lastReplicationAction)
And then you can specify node type for which this index is applicable in declaringNodeTypes field (i.e. cq:PageContent)
These should work.
For more info on above properties:
Checkout documentation : https://jackrabbit.apache.org/oak/docs/query/indexing.html
And these relevant references :
Vistas
Respuestas
Total de me gusta
When creating a property index in AEM, you typically only need to specify the property name itself, without the full node path. This is because property indexes focus on indexing individual property values within nodes, not the entire node structure.
Vistas
Respuestas
Total de me gusta
Hi @aemUser2345
It seems like you are encountering an issue with creating a custom index on jcr:content/cq:lastReplicationAction.The error message "Not a Valid JCR Name" suggests that there might be an issue with the syntax or format of the index definition
Make sure that the name attribute in the <cq:lastReplicationAction> property definition adheres to the rules for valid JCR names.
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://www.apache.org/jackrabbit/sling/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"
jcr:primaryType="sling:OsgiConfig"
reindex="true">
<!-- Define the custom index -->
<index
jcr:primaryType="oak:QueryIndexDefinition"
async="async"
compatVersion="{Long}2"
evaluatePathRestrictions="{Boolean}false"
type="lucene">
<!-- Specify the index rules -->
<indexRules jcr:primaryType="nt:unstructured">
<nt:base
jcr:primaryType="nt:unstructured">
<properties
jcr:primaryType="nt:unstructured">
<cq:lastReplicationAction
jcr:primaryType="nt:unstructured"
name="cq:lastReplicationAction"
type="String"/>
</properties>
</nt:base>
</indexRules>
</index>
</jcr:root>
Vistas
Respuestas
Total de me gusta
@aemUser2345
For Property Index in OakIndexDefinition,
You need not specify path of the property, just go with all properties in propertyNames field (i.e. cq:lastReplicationAction)
And then you can specify node type for which this index is applicable in declaringNodeTypes field (i.e. cq:PageContent)
These should work.
For more info on above properties:
Checkout documentation : https://jackrabbit.apache.org/oak/docs/query/indexing.html
And these relevant references :
Vistas
Respuestas
Total de me gusta
@aemUser2345 Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.
Vistas
Respuestas
Total de me gusta
Vistas
me gusta
Respuestas
Vistas
me gusta
Respuestas
Vistas
me gusta
Respuestas