Logging Best Practices

Loggers are the saviors for any project. Without loggers it would become impossible to identify RCA for any issue. But it is also important to understand when and how to write loggers. In this article I will go through few of the basics of the loggers and its best practices. Logging is a huge topic […]

Apache Felix SCR annotations details

SCR Annotations The maven-scr-plugin uses the SCR annotations from the corresponding subproject at Apache Felix. All annotations are in the org.apache.felix.scr.annotations package. If you want to use the annotations in your project, you have to use a maven-scr-plugin version >= 1.2.0 and make sure that you add a dependency to the annotations to your POM: <dependency> <groupId>org.apache.felix</groupId> <artifactId>org.apache.felix.scr.annotations</artifactId> <version>1.9.6</version> </dependency> The following annotations are […]

AEM 6.2 Touch UI Dialog Validation

In this article, I will walk you through a simple Touch UI dialog field validation. The validation framework has changed for Touch UI. This uses Granite Foundation Validation framework to validate the dialog fields. Requirement: If a text field has more than 9 characters, the dialog should show an error. Solution: Step 1: Create a […]

How to get Service Resource Resolver?

In AEM 6.1, there are lot of changes related to security. One of the important change is related to Admin Resource Resolver. Administrative Resource Resolver has always been used without much knowledge on the impacts on Security and Session related exceptions.  In AEM 6.1, getAdministrativeResourceResolver() method is deprecated and should no longer be used. The […]

Sightly + Sling Models Amazing Combination

I’m very impressed with Sling Models, they provide easy and very effective binding mechanism. The combination of Sightly and Sling Models is simply superb. It has made the developers life very easy. Here is a simple example of retrieving the multifield values using Sling Models and Sightly. The screen shot below shows the node structure […]