AEM OOTB Sitemap Scheduler is not generating Sitemaps | Community
Skip to main content
Level 2
April 26, 2023
Solved

AEM OOTB Sitemap Scheduler is not generating Sitemaps

  • April 26, 2023
  • 4 replies
  • 2935 views

Hello,

We’re upgrading AEM Service Pack to use Sitemap feature and trying to setup a scheduler for Sitemap Generation (org.apache.sling.sitemap.impl.SitemapScheduler) but It’s not able to execute and in error.log, getting this:

 

 

org.apache.jackrabbit.oak.plugins.index.Cursors$TraversingCursor Traversed 3000 nodes with filter Filter(query=select [jcr:path], [jcr:score], * from [nt:base] as a where [sling:sitemapRoot] = true and isdescendantnode(a, '/content/we-retail/us') option(index tag [slingSitemaps]) /* xpath: /jcr:root/content/we-retail/us//*[@sling:sitemapRoot=true] option(index tag slingSitemaps) */, path=/content/we-retail/us//*, property=[:indexTag=[slingSitemaps], sling:sitemapRoot=[true]]); consider creating an index or changing the query

Since this query get's generated based on what we enter in scheduler So, not sure if we can change the query here somehow?

So, I tried indexing but still it doesn't seem to work.

 

 


Can anyone suggests what I'm missing here?


Regards,

Radha

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 aemuser2021

Thankyou @dipti_chauhan . 

Issue is fixed now. I've created a index for sling:sitemapRoot property and created a config /apps/weretail/config.publish/org.apache.sling.sitemap.impl.SitemapScheduler~weretail.cfg.json inside config.publish folder. 

Earlier I was creating this config directly from /system/console/configMgr and seems like it was not picking up the correct config, if create it from configMgr.

Regards,

Radha

4 replies

Tanika02
Level 7
April 26, 2023

Hello @aemuser2021  - 

 

I would suggest you to go through this blog https://aemsimplifiedbynikhil.wordpress.com/2021/12/01/apache-sling-sitemap-for-aem-6-5-11-and-aemaacs/ 

 

This should be solving the problem. But let me know if does not solve your problem.

Level 2
April 26, 2023

Hi @tanika02 ,

Thankyou for sharing this. I've followed this article only for setting up the scheduler but it's not able to solve my issue. 

I've tried adding this new property too on the node: /oak:index/siteMap but after this scheduler is not even getting initiated.

 

 

Tanika02
Level 7
April 26, 2023

@aemuser2021  - Could you please share the error.log to understand the issue better?

Level 2
April 26, 2023

Hi @tanika02 ,

Here's the error.log -

 

26.04.2023 23:06:00.002 *WARN* [sling-default-5-My Sitemap Scheduler] org.apache.jackrabbit.oak.query.QueryImpl Traversal query (query without index): select [jcr:path], [jcr:score], * from [nt:base] as a where [sling:sitemapRoot] = true and isdescendantnode(a, '/content/we-retail/us') option(index tag [slingSitemaps]) /* xpath: /jcr:root/content/we-retail/us//*[@sling:sitemapRoot=true] option(index tag slingSitemaps) */; consider creating an index 26.04.2023 23:06:00.012 *WARN* [sling-default-5-My Sitemap Scheduler] org.apache.jackrabbit.oak.plugins.index.Cursors$TraversingCursor Traversed 1000 nodes with filter Filter(query=select [jcr:path], [jcr:score], * from [nt:base] as a where [sling:sitemapRoot] = true and isdescendantnode(a, '/content/we-retail/us') option(index tag [slingSitemaps]) /* xpath: /jcr:root/content/we-retail/us//*[@sling:sitemapRoot=true] option(index tag slingSitemaps) */, path=/content/we-retail/us//*, property=[:indexTag=[slingSitemaps], sling:sitemapRoot=[true]]); consider creating an index or changing the query 26.04.2023 23:06:00.022 *WARN* [sling-default-5-My Sitemap Scheduler] org.apache.jackrabbit.oak.plugins.index.Cursors$TraversingCursor Traversed 2000 nodes with filter Filter(query=select [jcr:path], [jcr:score], * from [nt:base] as a where [sling:sitemapRoot] = true and isdescendantnode(a, '/content/we-retail/us') option(index tag [slingSitemaps]) /* xpath: /jcr:root/content/we-retail/us//*[@sling:sitemapRoot=true] option(index tag slingSitemaps) */, path=/content/we-retail/us//*, property=[:indexTag=[slingSitemaps], sling:sitemapRoot=[true]]); consider creating an index or changing the query 26.04.2023 23:06:00.032 *WARN* [sling-default-5-My Sitemap Scheduler] org.apache.jackrabbit.oak.plugins.index.Cursors$TraversingCursor Traversed 3000 nodes with filter Filter(query=select [jcr:path], [jcr:score], * from [nt:base] as a where [sling:sitemapRoot] = true and isdescendantnode(a, '/content/we-retail/us') option(index tag [slingSitemaps]) /* xpath: /jcr:root/content/we-retail/us//*[@sling:sitemapRoot=true] option(index tag slingSitemaps) */, path=/content/we-retail/us//*, property=[:indexTag=[slingSitemaps], sling:sitemapRoot=[true]]); consider creating an index or changing the query 26.04.2023 23:06:00.041 *WARN* [sling-default-5-My Sitemap Scheduler] org.apache.jackrabbit.oak.plugins.index.Cursors$TraversingCursor Traversed 4000 nodes with filter Filter(query=select [jcr:path], [jcr:score], * from [nt:base] as a where [sling:sitemapRoot] = true and isdescendantnode(a, '/content/we-retail/us') option(index tag [slingSitemaps]) /* xpath: /jcr:root/content/we-retail/us//*[@sling:sitemapRoot=true] option(index tag slingSitemaps) */, path=/content/we-retail/us//*, property=[:indexTag=[slingSitemaps], sling:sitemapRoot=[true]]); consider creating an index or changing the query

 



 

Dipti_Chauhan
Community Advisor
Community Advisor
April 27, 2023

HI @aemuser2021 

  Can you please check this post - https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/apache-slign-sitemap-oak-index/td-p/448358

similar issue is discussed there. 

 

Thanks

Dipti

aemuser2021AuthorAccepted solution
Level 2
April 28, 2023

Thankyou @dipti_chauhan . 

Issue is fixed now. I've created a index for sling:sitemapRoot property and created a config /apps/weretail/config.publish/org.apache.sling.sitemap.impl.SitemapScheduler~weretail.cfg.json inside config.publish folder. 

Earlier I was creating this config directly from /system/console/configMgr and seems like it was not picking up the correct config, if create it from configMgr.

Regards,

Radha

DEBAL_DAS
New Member
September 4, 2023

Could you please let me know your index for sling:sitemapRoot property.

 

I have tried with following oak:index -

<siteMap jcr:primaryType="oak:QueryIndexDefinition" async="[async]" compatVersion="{Long}2" evaluatePathRestrictions="{Boolean}true" includedPaths="[/content/we-retail/us]" reindex="{Boolean}false" reindexCount="{Long}5" seed="{Long}3408412449185876957" type="lucene"> <indexRules jcr:primaryType="nt:unstructured"> <nt:base jcr:primaryType="nt:unstructured" includePropertyTypes="all"> <properties jcr:primaryType="nt:unstructured"> <sitemapRoot jcr:primaryType="nt:unstructured" name="sling:sitemapRoot" propertyIndex="{Boolean}true" type="Boolean"/> </properties> </nt:base> </indexRules> </siteMap>

 and it was unable to generate sitemap.

Debal Das, Senior AEM Consultant
Level 2
September 7, 2023

Hello @debal_das ,

We've got the package from Adobe to fix the Sitemap Indexing issue. Please check this link:
https://docs.mktossl.com/docs/experience-manager-65/release-notes/service-pack/6.5.11.html?lang=en