AEM as a Cloud: java.lang.IllegalStateException: Parent node at path [/oak:index] not found while adding new index definition
Hi Team,
I created a custom index for an AEM as a cloud environment. deployment is successful.
But in deployment logs, I am getting the following error log.
Can someone please help with what I am missing?
java.lang.IllegalStateException: Parent node at path [/oak:index] not found while adding new index definition for [/oak:index/acme.xxxxxxxxx-custom-1]. Intermediate paths node must exist for new index nodes to be created
at com.google.common.base.Preconditions.checkState(Preconditions.java:197)
at org.apache.jackrabbit.oak.plugins.index.importer.IndexDefinitionUpdater.apply(IndexDefinitionUpdater.java:82)
at org.apache.jackrabbit.oak.plugins.index.importer.IndexDefinitionUpdater.apply(IndexDefinitionUpdater.java:71)
at org.apache.jackrabbit.oak.index.IndexerSupport.updateIndexDefinitions(IndexerSupport.java:118)
at org.apache.jackrabbit.oak.index.IndexerSupport.switchIndexLanesAndReindexFlag(IndexerSupport.java:133)
at org.apache.jackrabbit.oak.index.OutOfBandIndexerBase.reindex(OutOfBandIndexerBase.java:76)
at com.adobe.granite.indexing.tool.ReindexCmd.index(ReindexCmd.java:132)
at com.adobe.granite.indexing.tool.ReindexCmd.run(ReindexCmd.java:94)
at com.adobe.granite.indexing.tool.Main.main(Main.java:67)
The index definition is:
<acme.xxxxxxxxxxxxxx-custom-1
jcr:primaryType="oak:QueryIndexDefinition"
async="async"
compatVersion="{Long}2"
evaluatePathRestrictions="{Boolean}true"
type="lucene">
<indexRules jcr:primaryType="nt:unstructured">
<cq:PageContent
jcr:primaryType="nt:unstructured"
includePropertyTypes="all">
<properties jcr:primaryType="nt:unstructured">
<xxxxxxxxxxxxxx
jcr:primaryType="nt:unstructured"
propertyIndex="{Boolean}true"
name="xxxxxxxxxxxxxx"/>
<yyyyyyyyy
jcr:primaryType="nt:unstructured"
propertyIndex="{Boolean}true"
name="yyyyyyyyy"/>
<zzzzzzzzzzz
jcr:primaryType="nt:unstructured"
propertyIndex="{Boolean}true"
name="zzzzzzzzzzz"/>
<axaxaxaxxa
jcr:primaryType="nt:unstructured"
propertyIndex="{Boolean}true"
name="axaxaxaxxa"/>
</properties>
</cq:PageContent>
</indexRules>
</acme.xxxxxxxxxxxxxx-custom-1>