Tuesday, 1 November 2016

Extending the Multi Site Manager using the Experience Manager MSM API

You can use the Adobe Experience Manager Muli Site Manager (MSM) API to create a custom service that is invoked when you perform a MSM operation such as create a LiveCopy page. Multi Site Manager  enables you to easily manage multiple web sites that share common content. MSM lets you define relations between the sites so that content changes in one site are automatically replicated in other sites.

For example, web sites are often provided in multiple languages for international audiences. When the number of sites in the same language is low (three to five), a manual process for syncronizing content across sites is possible. However, as soon as the number of sites grows or when multiple languages are involved, it becomes more efficient to automate the process.

A service that works with Experience Manager MSM functionality is implemented as an OSGi bundle and uses APIs located in the  com.day.cq.wcm.api package.

Note: For information about MSM functionality, see Multi-Site Management.

The main MSM API objects interact as follows:

Blueprint
A Blueprint defines the pages from which a live copy can inherit content. The use of a blueprint is optional but is required to push modifications to live copies that are inheriting from this blueprint or to define the default rollout configuration for the live copy that is in relation with the blueprint.

LiveCopy
A LiveCopy is the configuration of the relationship (LiveRelationship) between a page and its blueprint page. Use the LiveCopy class to access to the path of the page, the path of the blueprint page, the Rollout Configs, and whether child pages are also included in the LiveCopy.

LiveRelationship
The LiveRelationship represents the relationship between a resource and a blueprint. LiveRelationship objects provide access to the Rollout Configs, LiveCopy, and LiveStatus objects of the relationship. It also provides access to the paths of the target and source pages.

For example, a Live Copy is created in /content/copy from the blueprint at /content/geometrixx. The resources /content/geometrixx/en/jcr:content and /content/copy/en/jcr:content form a relationship.

LiveStatus
LiveStatus objects provide access to the runtime status of a LiveRelationship. Use to query the synchronization status of a Live Copy.

LiveAction
A LiveAction is an action that is executed on each resource that is involved in the rollout.
LiveActionFactory
Creates LiveAction objects given a LiveAction configuration. Configurations are stored as resources in the repository.

This development article steps you through how to use the MSM API. To read this article, click https://helpx.adobe.com/experience-manager/using/Extending_MSM.html.



Join the Experience League

To become an Experience Business, you need more than just great tools and online help. You need a partner. Experience League is a new enablement program with guided learning to help you get the most out of Adobe Experience Cloud. With training materials, one-to-one expert support, and a thriving community of fellow professionals, Experience League is a comprehensive program designed to help you become your best.

Join the Adobe Experience League by clicking this banner.




I (Scott Macdonald) am a Senior Experience League Community Manager at Adobe Systems with 20 years in the high tech industry. I am also a programmer with knowledge in Java, JavaScript, C#,C++, HTML, XML and ActionScript. If  you would like to see more AEM or other end to end articles like this, then leave a comment and let me know what content you would like to see.


Twitter: Follow the Digital Marketing Customer Care team on Twitter @AdobeExpCare.