AEM Interview Questions Part 5

This is part five of my AEM interview questions. You find the other parts here:

Part 1 - Part 2 - Part 3 - Part 4 - 
Part 6 - Part 7 - Part 8 - PDF

Here are some more AEM interview questions that could come up during a technical interview:


QWhat is a replication agent?


A: A replication agent is used to publish active content from the author environment to the publish environment, to flush content from the dispatcher cache, and return user input from the publish environment to the author environment. The replication agents are central to AEM.

Q: What is resource mapping?

A: Resource mapping is used to define redirects, vanity URLs and virtual hosts for AEM. You can use resource mapping to prefix all requests with “/content” so the internal structure of the AEM site is hidden from your visitors. You can also use resource mapping to define a redirect so that all requests to the gateway page of your site are redirected to another site.

Q: What is resource resolution in Sling?

A: Resource resolution in Sling is how Sling takes a URL and attempts to resolve it to a script. This is done by extracting information from the URL. Here is an example URL:

http://myhost/tools/spy.printable.a4.html/a/b?x=12

It can be broken down as follows:

Protocol
Host
Content path
Selector(s)
Extension

Suffix

Param(s)
http://
myhost
tools/spy
.printable.a4.
html
/
a/b
?
x=12

Sling uses the content path that is extracted from the request to locate the resource in the JCR. When this resource is located, the sling resource type is extracted, and then it is used to located the script to be used for rendering that content.

    Q: What design patterns are used in AEM?

    A: Since AEM is built using OSGI, many of the design patterns for OSGI are valid. Some of these design patterns are Singleton (Service), Adapter Service, Resource Adapter Service, and Whiteboard. 

    Also, since AEM is modular, you should be able to use any design pattern in your application.

    Q: What is reverse replication?

    A: Reverse replication is the process of replicating content from publish environment to the author environment. In order to accomplish this you need a reverse replication agent on your author instance that is configured to get content from the publish environment outbox.

    I plan to add more interview questions to this blog, so make sure to check back.

    I hope you enjoyed this post. Please feel free to post any comments below.