80. Sling Servlet in AEM.

Опубликовано: 17 Октябрь 2024
на канале: AEM and Devops Tutorial
20,202
135

Sling Servlet in AEM. If you have ever worked with java web application, you might have worked with servlets before. Servlets handle the request coming into a java based web application.

Sling appliation use scripts/servlets to process http request in a restful way. Sling is resource oriented which maps into a JCR nodes. With sling a request url is first resolved to a resource and then based on the resource, it selects the actual servlet/script to handle request.

Requests are handled by either script/Servlet in AEM. We can access servlets in two ways.
1. path
2. resourcepath.

Copy the code from url : https://github.com/pankajchhatri/AEM
Servlets are registered as osgi service/bundle. Defining the servlet using scr annotations has been deprecated from aem 6.2 that's why I have used osgi declarative service annotations in this video.

share, support, like and subscribe
Subscribe : https://www.youtube.com/channel/UC5Lc...
LinkedIn :   / pankaj-ch.  .
Facebook :   / pankajchhatri  
Twitter :   / pankajchhatri  
Google plus : https://plus.google.com/u/0/+pankajch...

About : AEM/CQ5 tutorial is a youtube channel which helps you to learn AEM concepts theoretically as well as practically.



Follow the video to create sling servlet using path. In the next clip I will cover how to create servlet by resource path.