Support Questions

Find answers, ask questions, and share your expertise

Setting the time in the Run Schedule of a processor

avatar
Expert Contributor

Hi All,

Thanks a lot to this awesome community

There is a use case where my processor should run daily at time 9:01 am cst.

question 1. Does it follow any time zone, do I need to provide it?

In addition after reading the docs here https://docs.hortonworks.com/HDPDocuments/HDF1/HDF-1.2/bk_UserGuide/content/scheduling-tab.html

my value for Run schedule would look like for every day at 9:01 am cst

* 01 09 * * *

does the above value look correct?

1 ACCEPTED SOLUTION

avatar
Master Guru

@dhieru singh

in processor scheduling tab click on Scheduling strategy and select Cron Driven and in Run schedule change the cron expression to

0 1 9 1/1 * ? *

it follows your local timezone.

So if you want to run at cst time then you need to adjust cron scheduling by cst time.

Example:-

If i need to run processor at 9:01am CST time and my local time is EST then i need to schedule processor to run at 8:01am EST because EST is 1 hour ahead of CST.

Expression would be

 0 1 8 1/1 * ? *

You can make or evaluate cron expressions by using below link

http://www.cronmaker.com/

View solution in original post

5 REPLIES 5

avatar
Master Guru

@dhieru singh

in processor scheduling tab click on Scheduling strategy and select Cron Driven and in Run schedule change the cron expression to

0 1 9 1/1 * ? *

it follows your local timezone.

So if you want to run at cst time then you need to adjust cron scheduling by cst time.

Example:-

If i need to run processor at 9:01am CST time and my local time is EST then i need to schedule processor to run at 8:01am EST because EST is 1 hour ahead of CST.

Expression would be

 0 1 8 1/1 * ? *

You can make or evaluate cron expressions by using below link

http://www.cronmaker.com/

avatar

@dhieru singh @Shu

It will only use your local timezone if the system NiFi is running on is configured to use your timezone. If your system is configured to use GMT, then you will have to adjust your cron schedule to account for the time difference.

avatar
Expert Contributor

@Wynner By local time zone we mean the system time on my nifi nodes.

avatar
@dhieru singh

Thank you for the clarification. From the discussion that was not clear to me.

avatar
Expert Contributor

@Wynner Thanks a lot and appreciate your help always