Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

Node structure for page a under /tmp/versionhistory is not similar to the node structure under /content/we-retail

Avatar

Level 2

Hi All,

I'm trying to use the page versionhistory functionality available in AEM. However, when I'm creating the page version of a specific page, the node structure of the parent nodes is not entirely getting created under the /tmp/versionhistory. 
For instance: I'm creating the version of page under /content/we-retail/us/en which is having the following node structure:

H_Malhotra_2-1646917249698.png

The node structure created under the temp/versionhistory node is as follows:

H_Malhotra_3-1646917626894.png

The image node available under content/we-retail/jcr:content is not available in the similar hierarchy under /tmp/versionhistory node structure.

Could you please let me know how can I generate the same node strucute 

 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @H_Malhotra, I think you are looking for version under incorrect location. The version itself is stored under /jcr:system/jcr:versionStorage - you can navigate to the versions of specific page by clicking on value of jcr:versionHistory property. There you will find complete copy that has been created as a version.

versions.jpg

/tmp/versionhistory is used by version comparison functionality. Which in general allows authors to compare visual/content differences between 2 versions. You are not seeing this image node because it looks it is not needed for comparison - as far as I know it stores image set under page properties, and comparison tool is not allowing you to show changes from page properties.

If you want to use AEM versioning functionality, you should use versions kept under /jcr:system/jcr:versionStorage - and Jcr Version Manger API to do any operation related to versions from the code.

 

View solution in original post

3 Replies

Avatar

Correct answer by
Community Advisor

Hi @H_Malhotra, I think you are looking for version under incorrect location. The version itself is stored under /jcr:system/jcr:versionStorage - you can navigate to the versions of specific page by clicking on value of jcr:versionHistory property. There you will find complete copy that has been created as a version.

versions.jpg

/tmp/versionhistory is used by version comparison functionality. Which in general allows authors to compare visual/content differences between 2 versions. You are not seeing this image node because it looks it is not needed for comparison - as far as I know it stores image set under page properties, and comparison tool is not allowing you to show changes from page properties.

If you want to use AEM versioning functionality, you should use versions kept under /jcr:system/jcr:versionStorage - and Jcr Version Manger API to do any operation related to versions from the code.

 

Avatar

Level 2

Thank you for your response @lukasz-m .

There are a few points that we are having issue with in our project structure, which can be understood by the below reference.
1. The image node available under content/we-retail/jcr:content is essential to compare/preview the page version created for /content/we-retail/us/en/women. Since the image node is not available under the /tmp/versionhistory node structure, the compare to current and preview functionalities lead to a blank page.
2. While previewing the page version, a few properties stored under /content/we-retail/us/jcr:content are necessary, which are missing under the /tmp/versionhistory node structure.

Avatar

Level 2

Hi @lukasz-m 

 

Can we export the specific version data as package archive from "/jcr:system/jcr:versionStorage" path to an external storage before it gets purged from AEM repo and then later reinstall it. 

Also, when we preview current page data to a specific version, AEM brings that version data in "/tmp/versionhistory" path along with few parent level nodes data like /content/we-retail/us/en. How is this currently accomplished. If we have a package archive of an old version externally, can we generate /tmp/versionhistory data from it somehow?

 

Thanks,

Pardeep