on 04-02-2015 1:35 AM
Hi Everyone,
CPS build M33.104.
We have two jobs, one for PST and another for PDT and are mutually exclusive.
The days on which the Day light savings switch happens is not constant, it changes from year to year.
2015 - Mar 8 - Nov 1
2014 - Mar 9 - Nov 2
How do i create a time window that is open only for summer and another, only for winter.
thanks
Nanda
Hi Nanda,
I must admit this is a very interesting request and I am trying to think of alternative implementations as no Time Window element currently exists that can test for DST changes.
My question is: in what sense are these jobs mutually exclusive. The main reason I can think of is that these are actually the same jobs, but they might require different scheduling or parameter sets. If that is the case you can resolve that with dynamic parameter settings based on the date or using preconditions or time windows to change the scheduling.
You can also put both jobs in the same step and put a preconditions on the jobs to test if the offset is correct depending on whether DST is active or not.
For instance: =Time.format(Time.now('PST'), 'Z') === '-0700' // Check the current offset, if it is -0700 we are in summertime
Regards Gerben
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
thanks
Nanda
First, I will admit to knowing almost nothing about CPS.
But consider that even though the start and end of summer/winter, or daylight saving time, fall on different dates each year, those do follow rules. In the United States, "daylight saving time starts on the second Sunday in March and ends on the first Sunday in November, with the time changes taking place at 2:00 a.m. local time" [Daylight saving time in the United States - Wikipedia, the free encyclopedia]. Perhaps you can work with these rules to create the time windows.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.