Hello Andreas,
We found the root cause of this problem.
This is happening due to the date format string using 'YYYY' instead of 'yyyy' in your policy.
As per our gateway documentation, our date time format is internally using SimpleDateFormat class from the Java SDK.
You can check out this docops link (https://docops.ca.com/ca-api-gateway/9-3/en/reference/context-variables/date-and-time-variables )and search for 'SimpleDateFormat.html', it will give you a reference to the JDK documentation.
Upon referring the same link (https://docs.oracle.com/javase/8/docs/api/java/text/SimpleDateFormat.html) , it was evident that 'Y' and 'y' behaviour is indeed very different 'y' -> Year whereas 'Y' -> Week Year To understand, as to why both of these return different values.
Here is a javadoc link (https://docs.oracle.com/javase/7/docs/api/java/util/GregorianCalendar.html#week_year) to show the difference.
Please search for 'Week Of Year and Week Year' in that doc and notice the line with the following text : 'A week year is in sync with a WEEK_OF_YEAR cycle. All weeks between the first and last weeks (inclusive) have the same week year value. Therefore, the first and last days of a week year may have different calendar year values.'
It is due to this, customer was getting different values on using capital 'Y' instead of small 'y'.
Thanks.
Regards
-SAyeed
CA Support