Tricky CQ5 Interview Questions for Beginners
Tricky Adobe CQ5 Interview Questions for Beginners-Here is a list of Adobe CQ5 interview questions and answers for beginners to help you in cracking interviews which many of my friend faced, in their technical round. I have also read many forum and sites to consolidate all important adobe CQ5 Interview Questions also known as AEM(Adobe Experience Manager).
In this section we will cover few tricky :
AEM(CQ5) basic interview questions.
AEM(CQ5) admin interview questions.
AEM(CQ5) testing interview questions.
AEM(CQ5) technical interview questions.
AEM(CQ5) certification questions.
What are the design patterns used in day CQ5?
We can use any design patterns that we like as OSGi makes CQ5 very modular, so we are free to use whatever suits our needs.
Why Sling Scripts cannot be called directly in CQ5?
Scripts cannot be called directly within Sling since it will break the strict concept of a REST server, you would mix resources and representations.
If you call the representation (the script) directly you hide the resource inside your script, so the framework (Sling) no longer knows about it.
What are the differences between CRX DE and Ecllipse ? What are the advantages of using CRXDE over Ecllipse for AEM Development?
- The major difference between Crxde and eclipse is Crxde comes with AEM and it runs on server side where as ecllipse runs on client side.
- CRXDE contains build in API’s for CRX(for Ex JCR, WebDav) where as in ecllipse we need to add extra plugin for supporting CRX API.
CRXDE is preferred for AEM Development. Below are the advantages of using CRXDE over Ecllipse:
Built-in Protocols/APIs for the CRX Platform. You can add, consume, and manage content with these interfaces:
- Java Content Repository API—a complete JCR 2.0 implementation
- Content Management Interoperability Services—CMIS 1.0
- WebDAV—with versioning, access control, and search
- Windows Network File Share—CIFS/SMB
- Java Remoting with RMI and HTTP
- LDAP and any JAAS plugin
- Native repository interface through a Virtual Repository, for example, Microsoft SharePoint
What are the differences between AEM and other CMS ?
AEM is preffered over other CMS because of following advantages:
- 100% built on Java. Hence platform independent.
- JSR-283 – a JCR
- Apache Felix – an OSGi framework
- Apache Sling – a web framework for the Java platform designed to create content-centric applications on top of a Java Specification Request (JSR)
- Apache Tika – a toolkit for detecting and extracting metadata and structured text content
What are the image format supported by AEM or CQ5?
AEM supports PNG, GIF, TIFF, JPEG, BMP, PNM, PGM, PBM, PPM, PSD, EPS, DNG format.
For more information visit Image Format supported by AEM
What do you mean by Overlay in AEM?
Copying content from /libs and pasting to /apps is known as overlay.This ability to override default functionality is called an
overlay. In overlay entire tree is copy and pasted including its parent and all child nodes.
What do you mean by Resource Merger in AEM?
Resource Merger does the same work of copying and pasting content from /libs to /apps. Only difference is with the help of resource merger.
What are the differences between Overlay and Sling Resource Merger?
Below are the differences between Overlay and Resource Merger:
|Overlay||Sling Resource Merger|
|Based on search paths (/libs + /apps)||Based on Resource Type Hierarchy|
|Need to copy the whole subtree||Extends within an almost empty subtree|
|All the properties are duplicated||Only required properties are overlaid|
|When upgrades are done to the /libs folder, these changes have to be manually recreated under /apps.||As properties are not copied, only the structure, upgrades are automatically|
reflected in /apps.
What will happen if i change the extension of page in url from html to json or xml ? How you can access data in different formats in AEM ?
- Access the following page:
Note: that you are getting an html representation of the page.
- Change the URL as follows, and access the page:
Note: that you are getting an xml representation of the page.
- Change the URL as follows, and access the page:
Note: that you are getting an json representation of the page.
Guess the output of below lines.
It is going to return only first json available on page.
We can return upto infinite json available on page using infinity as selector.
What are the advantages of using OSGI Architecture in AEM ?
OSGI Architecture is used in AEM because of following advantages:
- Code is easier to write and test.
- Increases reuse.
- Build systems become significantly simpler.
- Deployment is more manageable.
- Bugs are detected early.
- Runtime provides an enormous insight into what is running.
What is File Vault Tool (VLT) in Adobe CQ? Have you ever used it?
File Vault Tool (VLT) is a plugin from adobe which is used to map window file system structure with CQ file system structure.
What is xtype ?
xtype is your widget, which you place in your dialog to capture author data.
xtypes such as textfield, numberfield, selection etc.
What is Social Communities in CQ ? Have you ever worked on any Social Communities ?
Social Communities combines all social networking and collaboration applications within AEM, including:
- Social Login and Personalization
- Social Plugins
- Poll, Voting, Rating
- Community Groups
- Calendars and Events
- Spam Filtering
Yes, I have worked on Social Plugins. Learn to use Social Plugin.
Explain renditions in DAM?
DAM(digital asset management) allows you to create renditions of an image that include different sizes and versions of the same asset as shown below. You can use those renditions in the content of your website, and that can be helpful when you need to create thumbnails or smaller views of large, high-resolution images. When you are creating multi-device websites where Internet bandwidth is a varying concern, this feature becomes even more important. It makes your site load faster improves your search engine optimization and the user experience.
For Ex: If we upload a thumbnail image to a form then DAM stores its rendition on /content/dam/formsanddocuments/<Project>/renditions as shown in below figure.
Can we create page without template?
No, we cannot. When we go to form manager in cq then select sites -> project->create page after that next button won’t get enabled until we select a template.
How we can implement internationalization in CQ ?
we can implement internationalization by using l18n bundle approach. This is used to provide multilingual site functionality to website.
Below two steps should be kept in mind while implementing internationalization in cq:-
- Under apps–> <myapp> –>i18n –> <language Folder> should have jcr:language and jcr:mixinTypes as shown in below figure.
- Folder inside languagefolder should have a sling:key and sling:message property as shoen below.
For detailed explanation on how to implement internationalization click here.
List Implicit objects of CQ?
- slingRequest – The wrapped Request Object (SlingHttpServletRequest).
- slingResponse – The wrapped Response Object (SlingHttpServletResponse).
- resource – The Sling Resource Object (slingRequest.getResource();).
- resourceResolver – The Sling Resource Resolver Object (slingRequest.getResoucreResolver();).
- currentNode – The resolved JCR node for the request.
- log – The Default logger ().
- sling – The Sling script helper.
- properties – The properties of the addressed resource (resource.adaptTo(ValueMap.class);).
- pageProperties – The properties of the page of the addressed resource.
- pageManager – The page manager for accessing CQ content pages (resourceResolver.adaptTo(PageManager.class);).
- component – The component object of the current CQ5 component..
- designer – The designer object for retrieving design information (resourceResolver.adaptTo(Designer.class);).
- currentDesign – The design of the addressed resource.
- currentStyle – The style of the addressed resource.
What are the differences between sling:resourceType and sling:resourceSuperType ?
sling:resourceSuperType: It is used to achieve inheritance in cq. When set, it inherits the specified component to this component.
sling:resourceType: It is a path, which locates the script to be used for rendering the content. Path used can be absolute or relative.
What are the difference between
- <cq:include script=”layout-link.jsp” />
- <%@include file=”layout-link.jsp“%>
- <c:import url=”layout-link.jsp” />
- <sling:include path=”layout-link.jsp” />
CQ Include is most appropriate when you are doing standard component/template development.
Sling include is most appropriate when you are trying to include a piece of content as based strictly on sling resource resolution and not CQ component type logic.
<cq:include script=”layout-link.jsp” />
This is CQ specific Tag library. It understands CQ inheritance and we can provide both relative as well as absolute path. Scripts added using cq:include are executed added at run time. In addition to scripts we can also include components using <cq:include path=”” resourceType=””/>
This is include directive. It adds layout-link.jsp code to corresponding jsp file at compile time itself. Using include directive we can access methods from included directive at compile time itself.
<c:import url=”layout-link.jsp” />
I assume this is the import tag of the Standard Tag Library. This tag does not know about Sling directly.
But — assuming — this tag is using a RequestDispatcher to dispatch the request, this tag will also pass Sling and the Sling resource resolver.
<sling:include path=”layout-link.jsp” />
This is the include tag of the Sling JSP Tag library. This tag knows about Sling and also supportsRequestDispatcherOptions.
What is the use of CQ:defineObjects in AEM?
cq:defineObjects is used to initialize implicit objects of cq. Usually we add cq:defineObjects in global.jsp so that the implicit objects are available in all components that are including global.jsp.
Page property is disabled for newly created page in AEM ? What have you missed ?
Dialog is missing for this page.
What is Replication in CQ5?
- Publish (activate) content from author to publish environment.
- Explicitly flush content from the dispatcher cache.
- Return user input from the publish environment to the author environment.
- First, the author requests that certain content to be published (activated).
- The request is passed to the appropriate default replication agent.
- Replication agent packages the content and places it in the replication queue.
- The content is lifted from the queue and transported to the publish environment using the configured protocol.
- a servlet in the publish environment receives the request and publishes the received content, the default servlet is http://localhost:4502/bin/receive.
What is Reverse Replication?
Reverse replication is used to get user content generated on a publish instance back to the author instance. To do this you need a reverse replication agent in the author environment. This act as the active component to collect information from the outbox in the publish environment.
What is Personalization?
Personalization provides your users with a customized environment that displays dynamic content selected according to their specific needs.
There is an ever-increasing volume of content available today, be it on internet, extranet, or intranet websites.Personalization centers on providing the user with a tailor-made environment displaying dynamic content that is selected according to their specific needs; be this on the basis of predefined profiles, user selection, or interactive user behavior.
Teaser Component used in Personalization.
Can we restrict for certain users not to display some digital assets ?
You can always limit who can access certain folders in CQ Digital Assets by making the folder part of a CUG(closed user group).
Below are the Steps to make a folder part of a CUG:
- In CQ DAM, right-click the folder you want to add closed user group properties for and select Properties.
- Click the CUG tab.
- Select the Enabled check box to make the folder and its assets available only to a closed user group.
- Browse to the login page, if there is one, to add that information. Add admitted groups by clicking Add item. If necessary, add the realm.
- Click OK to save your changes.
How clustering is done in CQ5?
CQ5 CRX is pre-loaded to run within a cluster,even when running a single instance. Hence the configuration of multi-node clusters with little effort happens in CQ5.
How you can inherit properties of one dialog to another dialog ?
For inheriting properties we have to create two components with unique names in the base component dialog.
For eg. If your plan is to have two rich text two rich text areas in the dialog of components that inherit from the base, then you must include two rich text areas with unique names in the base component dialog. In any case every input field of a dialog must have a unique name, else they will point to the same property path relative to the jcr:content node of the component when used on a page.
Any issue if name is not unique?
Each input field of a dialog must have a unique name else both will point to the same property path relative to the jcr:content node of the component when used on a page.
Explain Multi-Site Management?
Multi-Site Management handles multilingual and multinational content, helping your company balance centralized branding with localized content
How to Synchronize User with LDAP in CQ ?
Ways to achieve synchronization of the user with LDAP are:-
- Manual synchronization of users using felix console
- Using CURL
Manual synchronization of users using felix console
- Open the felix jmx console and log in as admin at http://<host>:<port>/system/console/jmx
- Click on domain com.adobe.granite.ldap and it displays list of attributes and operations that can be performed.
- Click on operations and pops up with small window to supply parameter (if required). Ex:- syncUser operation, supply the DN of the single user (cn=user001,ou=users,dc=day,dc=com) to be synchronized
- Click Invoke to transfer appropriate details from the ldap directory server to CRX.
Synchronization of users Using CURL
- List Orphaned Users
curl -u <UID>:<PASSWORD> -X POST http://<HOST>:<PORT>/system/console/jmx/com.adobe.granite.ldap:host=<ldaphost>,port=<ldapport>,type=Tools/op/listOrphanedUsers/
- Sync All Users
curl -u <UID>:<PASSWORD> -X POST http://<HOST>:<PORT>/system/console/jmx/com.adobe.granite.ldap:host=<ldaphost>,port=<ldapport>,type=Tools/op/syncAllUsers/
- Sync User
curl -u <UID>:<PASSWORD> -X POST –data user=<cn=user001,ou=users,dc=day,dc=com> http://<HOST>:<PORT>/system/console/jmx/com.adobe.granite.ldap:host=<ldaphost>,port=<ldapport>,type=Tools/op/syncUser/java.lang.String
- Sync User List
Ex:- To sync 2 users user007 & user008 on my localhost
curl -u <UID>:<PASSWORD> -X POST –data userlist=%5B%22cn%3Duser007%2Cou%3Dusers%2Cdc%3Dday%2Cdc%3Dcom
- Purge Users
curl -u <UID>:<PASSWORD> -X POST http://<HOST>:<PORT>/system/console/jmx/com.adobe.granite.ldap:host=<ldaphost>,port=<ldapport>,type=Tools/op/purgeUsers/
- Sync Users
curl -u <UID>:<PASSWORD> -X POST http://<HOST>:<PORT>/system/console/jmx/com.adobe.granite.ldap:host=<ldaphost>,port=<ldapport>,type=Tools/op/syncUsers/
Leave a Reply