Do we have any easy way to manage the indexation ? | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by pulkitvashisth

For creating and managing custom queryIndexDefinition you can refer the documentation.
For reference, when you want to add custom index into a definition for a new metadata field :
1. Goto /oak:index/<customIndexDefinition>/indexRules/cq:Page/properties/
2. Create a new nt:unstructured node by the name of the new field to be indexed (like pageTitle)
3. Save node
4. Add properties to node -> (name, String, jcr:content/<fieldName>) (propertyIndex, Boolean, true)
5. Save all and goto /oak:index/<customIndexDefinition> 
6. Set reindex property to true and save.
The pages would be indexed wrt new metadata field.

2 replies

pulkitvashisth
pulkitvashisthAccepted solution
New Participant
January 2, 2024

For creating and managing custom queryIndexDefinition you can refer the documentation.
For reference, when you want to add custom index into a definition for a new metadata field :
1. Goto /oak:index/<customIndexDefinition>/indexRules/cq:Page/properties/
2. Create a new nt:unstructured node by the name of the new field to be indexed (like pageTitle)
3. Save node
4. Add properties to node -> (name, String, jcr:content/<fieldName>) (propertyIndex, Boolean, true)
5. Save all and goto /oak:index/<customIndexDefinition> 
6. Set reindex property to true and save.
The pages would be indexed wrt new metadata field.

Raja_Reddy
New Participant
December 30, 2023