Run Cron

This SDK can be used to execute a cron. The cron once executed will immediately submit the associated job to the job Pool. This can be done by passing the cron id or name to the runCron() SDK method.

Note: You can use this method to update details of both Pre-Defined Crons and Dynamic Crons.

Ensure the following packages have been imported:

    
copy
import com.zc.component.jobscheduling.beans.job.ZCJobDetails;
    
copy
ZCJobDetails runCronA = jobScheduling.cron.runCron(123456789l); // run cron with cron id ZCJobDetails runCronB = jobScheduling.cron.runCron("test_cron"); // run cron with cron name

Last Updated 2025-06-20 16:21:48 +0530 +0530