Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

Help with Experience Fragments Live Copy and Rollout

Avatar

Level 2

My site structure is as follows:

/content/mysite/language-masters/en
/content/mysite/us/en
/content/experience-fragments/mysite/language-masters/en
/content/experience-fragments/mysite/us/en

This site structure allows me to use the Localized Site Structure Support feature of the Core Experience Fragment component.

Now, I want to create a live copy of /content/mysite/language-masters/en to /content/mysite/ca/en, but there are two issues after the live copy of the site is created:

1. The Experience Fragments that exist on the pages of the Canada site do not update their references to point to /content/experience-fragments/mysite/ca/en.

2. I expect the live copy/rollout feature to create a copy of any referenced Experience Fragment to /content/experience-fragments/mysite/ca/en, but this does not happen either.

I've already created a custom LiveActionFactory class to resolve the first issue by regionalizing experience fragment path references based on the target resource. I am wondering if I need to update this class to also create copies of referenced experience fragments to /content/experience-fragments/mysite/(target-country)/(target-language) in order to mimic the Live Copy feature that exists under Sites.

1. Is this use case supported by OOTB AEM? I am on version 6.4.8 but soon upgrading to 6.5.12.

2. Is my solution to use a custom LiveActionFactory class to copy referenced XFs the only solution, or is there something else that we can do?

3. What are the best practices for this? They seem to be inconsistent because AEM recommends the site structure I have, however it only seems to support creating live copies of XFs as variations, which goes against the recommendation to use /content/experience-fragments/mysite/(country-code)/(language-code) as the experience fragment structure.

 

 

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

Hi @nydel09 ,

You are correct with your analysis. Experience does not support similar live copy creation as we do in sites. This is because AEM uses MSM relationships for experience fragment variations. So this doesn’t support this requirements. The use case you explained is pretty common but unfortunately XF doesn't support.

 

OOTB feature doesn't provide the feature to have the same hierarchy of live- and language-copies, as for the normal content. And you cannot have XPF references, that are automatically adjusted during rollout or translation of the normal content. Any modification you need to do in this behavior has to be custom overlays and modification of ootb feature.

 

The alternative is to create a content structure within you sites and try to achieve what you are trying with XF.

 

However, XF does support language copy creation an it does update the reference path in the site language copies.

View solution in original post

1 Reply

Avatar

Correct answer by
Employee Advisor

Hi @nydel09 ,

You are correct with your analysis. Experience does not support similar live copy creation as we do in sites. This is because AEM uses MSM relationships for experience fragment variations. So this doesn’t support this requirements. The use case you explained is pretty common but unfortunately XF doesn't support.

 

OOTB feature doesn't provide the feature to have the same hierarchy of live- and language-copies, as for the normal content. And you cannot have XPF references, that are automatically adjusted during rollout or translation of the normal content. Any modification you need to do in this behavior has to be custom overlays and modification of ootb feature.

 

The alternative is to create a content structure within you sites and try to achieve what you are trying with XF.

 

However, XF does support language copy creation an it does update the reference path in the site language copies.