Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

[AEM]-How to write Sling Jobs in AEM? | AEM Community Blog Seeding




[AEM]-How to write Sling Jobs in AEM? by Veena Vikraman


Everyday is a new learning. I keep my eyes and ears open to learn things which I might have missed to learn. I am ashamed to say that I was not aware of Sling Jobs for a very long time. But they say "Better late than never" . This is why it is always good to work under people or architects who know the technology and want to do things the right way than the easy way .

Since I have learned the benefits of using Sling Jobs , I would like to share my learning with all who are not yet aware of this . So let's first see what is a Job and what is its benefits

As per the official documentation

Jobs (Guarantee of Processing)
In general, the eventing mechanism (OSGi EventAdmin) has no knowledge about the contents of an event. Therefore, it can't decide if an event is important and should be processed by someone. As the event mechanism is a "fire event and forget about it" algorithm, there is no way for an event admin to tell if someone has really processed the event. Processing of an event could fail, the server or bundle could be stopped etc.
On the other hand, there are use cases where the guarantee of processing is a must and usually this comes with the requirement of processing exactly once. Typical examples are sending notification emails (or sms), post processing of content (like thumbnail generation of images or documents), workflow steps etc.

Read Full Blog

[AEM]-How to write Sling Jobs in AEM?


Please use this thread to ask the related questions.


Topics help categorize Community content and increase your ability to discover relevant content.

0 Replies