AEM scheduler performace impact | Community
Skip to main content
Level 3
February 22, 2016
Solved

AEM scheduler performace impact

  • February 22, 2016
  • 3 replies
  • 2039 views

Hi ,

As per one our project requirement we have execute some peace code Automatically every year on Jan-1.  We can implement this in AEM using Sling-schedulers. But as per our understanding if Any sling-scheduler is configured , A separate thread (For each scheduled-event) run allays on back end to check whether Trigger time for this scheduled event is reached and will execute code. In Our view this , this will have impact on Performance Of AEM (since thread corresponding to this scheduled event will always run continuously on back end). Please correct if our understanding is wrong.

Thanks

k Chaitanya

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Jitendra_S_Toma

 Yes. There is a daemon thread which keeps checking the scheduler timing. However, I don't think this could lead to a problem unless you are running scheduler very frequently.

-----Jitendra

krishna chaitanya wrote...

Hi ,

As per one our project requirement we have execute some peace code Automatically every year on Jan-1.  We can implement this in AEM using Sling-schedulers. But as per our understanding if Any sling-scheduler is configured , A separate thread (For each scheduled-event) run allays on back end to check whether Trigger time for this scheduled event is reached and will execute code. In Our view this , this will have impact on Performance Of AEM (since thread corresponding to this scheduled event will always run continuously on back end). Please correct if our understanding is wrong.

Thanks

k Chaitanya

 

3 replies

smacdonald2008
Level 10
February 22, 2016

AEM is made up of services like this - that is - usnig SLing APIs.

Sling services are part of AEM and this will not have any more impact than other Sling based services. Many development teams use Sling Scheduling functionality in their projects, See this Sling documentation for more information:

https://sling.apache.org/documentation/bundles/scheduler-service-commons-scheduler.html

https://sling.apache.org/apidocs/sling7/org/apache/sling/commons/scheduler/Scheduler.html

Having said this - create your service so its not fired too often. 

Jitendra_S_Toma
Jitendra_S_TomaAccepted solution
Level 10
February 23, 2016

 Yes. There is a daemon thread which keeps checking the scheduler timing. However, I don't think this could lead to a problem unless you are running scheduler very frequently.

-----Jitendra

krishna chaitanya wrote...

Hi ,

As per one our project requirement we have execute some peace code Automatically every year on Jan-1.  We can implement this in AEM using Sling-schedulers. But as per our understanding if Any sling-scheduler is configured , A separate thread (For each scheduled-event) run allays on back end to check whether Trigger time for this scheduled event is reached and will execute code. In Our view this , this will have impact on Performance Of AEM (since thread corresponding to this scheduled event will always run continuously on back end). Please correct if our understanding is wrong.

Thanks

k Chaitanya

 

joerghoh
Adobe Employee
Adobe Employee
February 23, 2016

Hi,

Sling and AEM are using the Quartz scheduler. I haven't checked the source yet, but I don't think that for each scheduled job a separate thread is being created. I also haven't observed this behaviour you assume in any threaddump I did on AEM instances in the last 3 years.

So I do think, that it is safe to create many scheduled jobs from a performance and load point of view. Jobs which are not scheduled do not consume performance.

kind regards,
Jörg