Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Using Adobe Experience Manager Versioning for Common Problems

Avatar

Avatar
Seeker
Community Manager
NimashaJain
Community Manager

Likes

37 likes

Total Posts

181 posts

Correct reply

1 solution
Top badges earned
Seeker
Engage 1
Applaud 50
Validate 10
Publish 100
View profile

Avatar
Seeker
Community Manager
NimashaJain
Community Manager

Likes

37 likes

Total Posts

181 posts

Correct reply

1 solution
Top badges earned
Seeker
Engage 1
Applaud 50
Validate 10
Publish 100
View profile
NimashaJain
Community Manager

10-11-2021

Author: Aditya Sharma

landing-banner.jpeg

First, a little about myself. I am a newbie into the world of Adobe Experience Manager (AEM), and I am blogging about the problems that I faced during my AEM development process. Here are some of the solutions I’ve jotted down along the way, after a lot of digging around and troubleshooting.

If you are looking for the official, exact know-how on implementing AEM versioning then I suppose this would be the link to check out. But, in case you are looking for answers to the more practical problems that we see in our day-to-day life with AEM—some of which can be relieved using the versioning mechanism—then read on.

Let’s begin our fun ride through a few of the problems that we encounter, and how AEM versioning can remedy those for us. Here’s the first scenario:

1. You are an author working on a page, but you have multiple other authors who are trying to make changes to the same page. At times this makes you lose changes you’ve made.

To answer this, we have a  available in AEM. Once you use this, the page cannot be edited by anyone other than you. If it’s that simple, you might wonder, what’s the harm in just using this? Nothing. But as soon as you unlock the page, nothing is stopping others from making further changes, and nothing guarantees your changes aren’t lost. Instead, I would suggest using versioning, rather than using the page lock, which makes sense when you are going to work for a long time on the same page or are about to make a lot of changes. But even after that, we should create a version from our page. Why? Because this gives you the option to revert your page to a previous version and retrieve your earlier changes.

Similarly, if everyone maintains their own versions, it becomes easier to revert, compare the various versions, and bring the page back to the state it should be in. You can read more about creating versions in AEM here.

2. A page has been accidentally deleted in AEM. You want to retrieve it, and figure out how it was deleted.

This is one of the more frequent problems, the straightforward answer to which, I could find nowhere. I am speaking from experience. I accidentally deleted one of the pages that was very critical and wanted to bring it back. But since the group I’m working with is not in the habit of creating versions, it’s difficult to do that.

After a lot of troubleshooting to figure out how exactly the page deletion works, I figured out that AEM is “smart” and helps you out. It does not simply go ahead and delete a page; it creates a version out of it before deleting the actual page. In case you want to retrieve it, you can go to the site admin screen and use the  options and the option as shown in the screenshot. Select the version for the page deleted and click  and voilayour page is back. That’s it!

tools drop down menu.pngNote that you should be on the path that the page was deleted from before trying to restore it, for the versions to be listed. So, for example, I had a page at the path , which I deleted; this meant I needed to be on the path to restore the page before clicking on the  option for the pages with available versions listed.

Now that this is sorted, let’s deep dive into how I figured this out.

AEM creates an audit trail for every page in the content root, and as such you should be able to view each manipulation of the page in one place, which is . AEM also audits DAM assets and replication, but that is a topic for another time. Now if you check the same path for the page that was deleted here, we would find multiple entries. Each entry shows the operation carried out, the person who did it, and when it was done. If you check this you should see individual entries for each action taken. When we delete a page, we see two entries: one with operation  and the other as . If you compare the two timestamps, they are just milliseconds apart. This is how I discovered the AEM auto-versioning feature, and this gives us vital information about which version of the page we would want to restore. See attached screenshot for the  entry.

version created entry.png

This screenshot tells us that the page “” was versioned and the version ID that was created is 1.0, and hence you would want to version that.

I will conclude this post by saying this is a cool feature to have, and if we use it diligently it would help a lot of heartache when content gets lost!

Until next time, CHEERS and happy versioning! 😊

Originally published: Oct 16, 2019