jcr:uuid not being generated for pages in AEM Cloud | Community
Skip to main content
Ankan_Ghosh
Level 3
December 4, 2024
Solved

jcr:uuid not being generated for pages in AEM Cloud

  • December 4, 2024
  • 4 replies
  • 1413 views

Recently we are noticing that newly created pages is not having any jcr:uuid associated with it. Is there any way to enable the automatic generation of jcr:uuid for every new page created. It was working fine when we checked last time. 

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 EstebanBustamante

Hi,

 

The creation of the jcr:uuid is provided by the mixin mix:referenceable. By default, pages won’t have this property so you won't have this by default either. 

 

Auto generating jcr:uuid? There could be tweaks to try to create the jcr:uuid when the page is first created, but I would not recommend this. Instead, use the default ID to identify any node in JCR (the path). If this is not sufficient, i think it’s preferable to come up with a custom solution for generating an ID.

 

References:

https://jackrabbit.apache.org/archive/wiki/JCR/Mix--referenceable_115513457.html

https://stackoverflow.com/questions/31012002/how-does-jackrabbit-generate-jcruuid-in-aem 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/aem-uuid/m-p/279559/highlight/true#M16209 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/what-is-mix-referenceable-in-aem/td-p/542234

 

Hope this helps.

4 replies

PRATHYUSHA_VP
Community Advisor
Community Advisor
December 4, 2024
Ankan_Ghosh
Level 3
December 4, 2024

I want to know about the potential reason behind the issue I am facing where uuid is not being generated. Any idea what can be the reason or a fix for this?

Asutosh_Jena_
Community Advisor
Community Advisor
December 4, 2024

Hi @ankan_ghosh 

Are you facing this issue in any specific instance/environment or in all environment? If in all environment, were there any changes made after which you started facing this issue?

Ankan_Ghosh
Level 3
December 5, 2024

Only on stage and prod environment. Dev is still generating the uuid after publishing the pages. I build the main branch locally and uuid is being generated in this case as well.

EstebanBustamante
Community Advisor and Adobe Champion
EstebanBustamanteCommunity Advisor and Adobe ChampionAccepted solution
Community Advisor and Adobe Champion
December 5, 2024

Hi,

 

The creation of the jcr:uuid is provided by the mixin mix:referenceable. By default, pages won’t have this property so you won't have this by default either. 

 

Auto generating jcr:uuid? There could be tweaks to try to create the jcr:uuid when the page is first created, but I would not recommend this. Instead, use the default ID to identify any node in JCR (the path). If this is not sufficient, i think it’s preferable to come up with a custom solution for generating an ID.

 

References:

https://jackrabbit.apache.org/archive/wiki/JCR/Mix--referenceable_115513457.html

https://stackoverflow.com/questions/31012002/how-does-jackrabbit-generate-jcruuid-in-aem 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/aem-uuid/m-p/279559/highlight/true#M16209 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/what-is-mix-referenceable-in-aem/td-p/542234

 

Hope this helps.

Esteban Bustamante
kautuk_sahni
Community Manager
Community Manager
January 7, 2025

@ankan_ghosh Did you find the suggestions helpful? Please let us know if you require more information. Otherwise, please mark the answer as correct for posterity. If you've discovered a solution yourself, we would appreciate it if you could share it with the community. Thank you!

Kautuk Sahni