Q4.) Describe Dispatcher

Dispatcher is Adobe Experience Manager’s caching and/or load balancing tool. Using AEM’s Dispatcher also helps to protect your AEM server from attack. Therefore, you can increase the security of your AEM instance by using the Dispatcher in conjunction with an enterprise-class web server.


Dispatcher is a CQ5 tool which has 2 Responsibilities.
1)    Caching – To cache as much content as possible, so that it doesn’t need to access layout engine frequently for generating content dynamically.
2)    Load-balancing – To increase the performance by load-balancing.

Dispatcher uses 2 main Strategies for caching.
1)    Cache as much content as possible as static pages.
2)    Accessing layout engine as little as possible.

Methods for Caching
The Dispatcher has two primary methods for updating the cache content when changes are made to the website.

  1. Content Updates remove the pages that have changed, as well as files that are directly associated with them.
  2. Auto-Invalidation automatically invalidates those parts of the cache that may be out of date after an update. i.e. it effectively flags relevant pages as being out of date, without deleting anything.

 Content Updates

In a content update, one or more AEM documents change. AEM sends a syndication request to the Dispatcher, which updates the cache accordingly:

  1. It deletes the modified file(s) from the cache.
  2. It deletes all files that start with the same handle from the cache. For example, if the file /en/index.html is updated, all the files that start with /en/index. are deleted. This mechanism allows you to design cache-efficient sites, especially in regard to picture navigations.
  3. It touches the so-called statfile; this updates the timestamp of the statfile to indicate the date of the last change.

Q5.) What is a Replication Agent

Replication agents are central to Adobe Experience Manager (AEM) as the mechanism used to:

  • Publish (activate) content from an author to a publish environment.
  • Explicitly flush content from the Dispatcher cache.
  • Return user input (for example, form input) from the publish environment to the author environment (under control of the author environment).

A development environment can contain multiple cq-author and multiple cq-publish instances, therefore an author instance can be configured to have many replication agents. Each of which will replicate the content in 1 or more publish instances.

  • Replication (Author to Publish): When a request is made from user to publish any content, then the replication agent packages the content and places it in a replication queue. A Listener servlet in publish instance receives the content package and updates the content in publish instance. The default listener servlet in publish instance is “http://localhost:4503/bin/recieve” .
  • Reverse Replication(Publish to Author): The content is moved from publish instance to author instance using reverse replication and the job is done by reverse replication agent.The reverse replication agent places any content updates in an outbox configured in publish instance (repo://var/replication/outbox ). The replication listeners in author environment keep listening to the publish outbox and whenever any content is placed in publish outbox, the listeners update the content in author instance.

Q6.) What is the technology Stack of CQ5 and describe each one of the  technologies used?

Cq5 uses the following technologies :
1) JCR – java specification for accessing a content repository JSR-283 specification jcr 2.0 , CQ5 uses its own implementation of jcr called CRX. Apache Jackrabbit is an open-source implementation of jcr 2.0 specification.
2) Apache Sling – RESTful framework to access a jcr over http protocol. It maps the request url to the node in jcr.
3) OSGi – framework for modular application development using java. Each module called bundle can be independently started and stopped.

CQ5 Technology Stack

Q7.) What is the architecture of CQ5 application?

The following diagram illustrates the interrelationship between CQ and other operational elements; which may be products from Day Management AG, or their third-party equivalents:

CQ5 Overview

Servlet Engine
The Servlet Engine acts as the server within which each CQ (and CRX if used) instance runs as a web application.

Any Servlet Engine supporting the Servlet API 2.4 (or higher) can be used.

Although you can run CQ WCM without an application server, a Servlet Engine is needed. Both CRX, and therefore CQ WCM, ship with Day’s CQSE (CQ Servlet Engine), which you can use freely and which is fully supported.

Java Content Repository (JCR)
A Java Content Repository uses the JSR-170 API to access the content repository using Java, independent of the physical implementation. JCR is the Java Content Repository standard, also known as JSR-170 after its Java Specification Request.

A repository effectively consists of two parts:

  • A Web application that offers the JSR-170 compliant API and temporary data storage (in the form of the session).
  • A Persistence Manager with persistent data storage, such as the file system or a database.

Content Repository Extreme (CRX) is Day Management AG’s own repository product. See the CRX documentation for more details; including direct access using WebDAV, CIFS, File Vault etc.

The common foundation of the CQ5 platform provides a basis for the interoperability and seamless integration of all CQ applications. This is available to both:

  • the applications that are integral to CQ itself
  • any customized applications developed for the CQ5 platform.

CQ WCM (Web Content Management) and the CQ Workflow Engine were the first applications developed to exploit the advantages of CQ5. CQ DAM and CQ Social Collaboration are now available and other Day products will be developed in the near future.

Inside CQ5

CQ5 Internal Layers

Web Content Management within the CQ5 platform allows you to generate and publish pages to your website..

CQ Workflow Engine
The CQ Workflow Engine is a powerful and easy to use process engine that can be used by all applications running on the CQ5 platform. A Java API and RESTful HTTP interface is also provided for access by applications outside CQ5.

Within CQ WCM workflows can be used to control the process of generating and publishing content, which are often subject to organizational processes, including steps such as approval and sign-off by various participants.

CQ Components
Components provide the logic (code) to render content. They include both templates and specific components such as Text with Image, Column Control and Subtitle amongst others. Components are based on a combination of widgets, replacing the CFC from Communiqué 4.

CQ Widgets
Widgets are the basic elements used to implement a specific user function, often the editing of a piece of content; they include buttons, radio-boxes, dialogs, etc.

Apache Sling
The Component Framework (Sling) provides the underlying mechanisms for rendering content.


5 thoughts on “Basics

  1. Pingback: How to Prepare ? – CQ5 AEM Tricks of Trade

  2. Pingback: AEM Interview Q & A | AEM basics & tactics

  3. Pingback: Wiring Harness Design Engineer Interview Questions - free wiring diagrams

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s