Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.
SOLVED

Add the custom oak lucene index to code base

Avatar

Level 4

Hi,

I am planning to get the prod custom lucene index content to merge in the code base. Please suggest the folder path or process for this.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @Beaula123 
It should be inside ui.apps but make sure you have enabled the allowIndexDefinitions in ui.apps POM as well

 

<allowIndexDefinitions>true</allowIndexDefinitions>

 

you can also create separate module for index example: https://github.com/valtech/aem-easy-content-upgrade/tree/master/oak.index 




Arun Patidar

View solution in original post

9 Replies

Avatar

Level 8

@Beaula123 

Custom index should be added in the path ui.apps/src/main/content/jcr_root/_oak_index

and add an entry in filter.xml in ui.apps folder (ui.apps/src/main/content/META-INF/vault/filter.xml)

Please check the below link for the steps

https://experienceleague.adobe.com/docs/experience-manager-cloud-service/content/operations/indexing...

Avatar

Correct answer by
Community Advisor

Hi @Beaula123 
It should be inside ui.apps but make sure you have enabled the allowIndexDefinitions in ui.apps POM as well

 

<allowIndexDefinitions>true</allowIndexDefinitions>

 

you can also create separate module for index example: https://github.com/valtech/aem-easy-content-upgrade/tree/master/oak.index 




Arun Patidar

Avatar

Level 4

Hi @arunpatidar , @AMANATH_ULLAH ,

This is working for the custom index. But, I am facing issues with OOTB indexes.

I have updated the OOTB Lucene index versionStorageIndex with needed properties and after deployment, the server went down. Please suggest.

Beaula123_0-1710314774390.png

Deployment Logs

 

ERROR] Request failed: org.apache.jackrabbit.vault.packaging.PackageException: org.apache.jackrabbit.oak.query.RuntimeNodeTraversalException: The query read or traversed more than 100000 nodes. To avoid affecting other tasks, processing was stopped. (500)

 

Error Logs:

13.03.2024 12:51:08.696 *ERROR* [qtp429498117-9814] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: AuthenticationSupport service missing. Cannot authenticate request.
13.03.2024 12:51:08.696 *ERROR* [qtp429498117-9814] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: Possible reason is missing Repository service. Check AuthenticationSupport dependencies.
13.03.2024 12:51:10.687 *ERROR* [qtp429498117-6930] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: AuthenticationSupport service missing. Cannot authenticate request.
13.03.2024 12:51:10.687 *ERROR* [qtp429498117-6930] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: Possible reason is missing Repository service. Check AuthenticationSupport dependencies.
13.03.2024 12:51:12.691 *ERROR* [qtp429498117-9814] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: AuthenticationSupport service missing. Cannot authenticate request.
13.03.2024 12:51:12.691 *ERROR* [qtp429498117-9814] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: Possible reason is missing Repository service. Check AuthenticationSupport dependencies.
13

Avatar

Community Advisor

Hi @Beaula123 
Can you check if anything is running like reindexing?

please wait for sometimes to check if server comes up.



Arun Patidar

Avatar

Level 4

@arunpatidar,

The logs might saying the same. The server is still down after few hours. Do we have an option to not trigger reindexing while deployment? Please suggest.

 

13.03.2024 20:14:30.853 *ERROR* [qtp1732250796-21263] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: AuthenticationSupport service missing. Cannot authenticate request.
13.03.2024 20:14:30.853 *ERROR* [qtp1732250796-21263] org.apache.sling.engine.impl.SlingHttpContext handleSecurity: Possible reason is missing Repository service. Check AuthenticationSupport dependencies.
13.03.2024 20:15:15.525 *INFO* [sling-default-2-health-com.adobe.granite.queries.impl.hc.QueriesStatusHealthCheck] com.adobe.granite.queries.impl.hc.QueriesStatusHealthCheck Could not retrieve QueryStats MBean.
13.03.2024 20:15:15.539 *WARN* [sling-default-2-health-com.adobe.granite.queries.impl.hc.QueryLimitsHealthCheck] com.adobe.granite.queries.impl.hc.QueryLimitsHealthCheck Could not retrieve QueryEngineSettings MBean.
13.03.2024 20:15:19.280 *ERROR* [sling-default-3-health-com.day.cq.compat.codeupgrade.impl.hc.MissingPackagesHealthCheck] com.adobe.granite.queries.impl.hc.QueryHealthCheckMetrics Error in refreshing the health check gauge
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected a string but was BEGIN_OBJECT at line 1 column 1480105 path $.data[580].contentPackage
at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:226) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.TypeAdapterRuntimeTypeWrapper.read(TypeAdapterRuntimeTypeWrapper.java:41) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.ArrayTypeAdapter.read(ArrayTypeAdapter.java:72) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.read(ReflectiveTypeAdapterFactory.java:131) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:222) [com.adobe.cq.gson:2.8.5]
at com.google.gson.Gson.fromJson(Gson.java:927) [com.adobe.cq.gson:2.8.5]
at com.google.gson.Gson.fromJson(Gson.java:865) [com.adobe.cq.gson:2.8.5]
at com.day.cq.compat.codeupgrade.impl.hc.MissingPackagesHealthCheck.getMissingBundleAndContentPackage(MissingPackagesHealthCheck.java:255) [com.day.cq.cq-compat-codeupgrade:1.7.100]
at com.day.cq.compat.codeupgrade.impl.hc.MissingPackagesHealthCheck.addMissingPackagesLogsToSet(MissingPackagesHealthCheck.java:226) [com.day.cq.cq-compat-codeupgrade:1.7.100]
at com.day.cq.compat.codeupgrade.impl.hc.MissingPackagesHealthCheck.execute(MissingPackagesHealthCheck.java:147) [com.day.cq.cq-compat-codeupgrade:1.7.100]
at com.adobe.granite.queries.impl.hc.QueryHealthCheckMetrics$LazyGauge.execute(QueryHealthCheckMetrics.java:266) [com.adobe.granite.queries:1.0.64]
at com.adobe.granite.queries.impl.hc.QueryHealthCheckMetrics$LazyGauge.lambda$new$0(QueryHealthCheckMetrics.java:253) [com.adobe.granite.queries:1.0.64]
at org.apache.sling.commons.scheduler.impl.QuartzJobExecutor.execute(QuartzJobExecutor.java:347) [org.apache.sling.commons.scheduler:2.7.2]
at org.quartz.core.JobRunShell.run(JobRunShell.java:202) [org.apache.sling.commons.scheduler:2.7.2]
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.IllegalStateException: Expected a string but was BEGIN_OBJECT at line 1 column 1480105 path $.data[580].contentPackage
at com.google.gson.stream.JsonReader.nextString(JsonReader.java:825) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.TypeAdapters$16.read(TypeAdapters.java:402) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.TypeAdapters$16.read(TypeAdapters.java:390) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.read(ReflectiveTypeAdapterFactory.java:131) [com.adobe.cq.gson:2.8.5]
at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:222) [com.adobe.cq.gson:2.8.5]
... 16 common frames omitted