Product:
Planning Analytics 2.0.9.18
Microsoft Windows 2019
Issue:
The time value in log file is not correct.
Solution:
Add
# Specify GMT or Local timezone
log4j.appender.S1.TimeZone=Local
to your tm1s-log.properties file that should be in the same folder as your tm1s.cfg file.
This should give you have logfiles with same time stamp as the clock on the server.
To test create a TI process with this in PROLOG:
In the log file you will see lines like this:
13972 [4a] INFO 2023-11-03 15:17:41.836 TM1.TILogOutput This is the end of the process !!!
13972 [4a] INFO 2023-11-03 15:17:41.836 TM1.Process Process “S. 10 Test of time value”: finished executing normally, elapsed time 0.02 seconds
When GMT is set, the time in the logfile will be ENGLISH TIME (GMT), and depending on time difference it will differ from the server time. Check https://24timezones.com/difference/gmt/stockholm
15296 [4a] INFO 2023-11-03 16:27:43.826 TM1.TILogOutput This is the end of the process !!!
15296 [4a] INFO 2023-11-03 16:27:43.826 TM1.Process Process “S. 10 Test of time value”: finished executing normally, elapsed time 0.00 seconds
With Local set in the file – the time in the logfile should be the same as the windows server clock.
In the text file will the time be shown as above – this is always the computer time of the server. Function NOW give the server time.
The Chore is run at local time when you select local. If UTC is selected it will run at the GMT time shown.
18032 [4] INFO 2023-11-04 07:14:29.923 TM1.Chore Registering chore: “S. 10 test of time” Start time: 2023/11/04 06:15:45 Frequency: 01:00:00:00
15736 [] INFO 2023-11-04 07:15:45.050 TM1.Chore Chore “S. 10 test of time” executed by scheduler
15736 [] INFO 2023-11-04 07:15:45.050 TM1.Process Process “S. 10 Test of time value” executed by chore “S. 10 test of time”
15736 [] INFO 2023-11-04 07:15:45.053 TM1.TILogOutput This is the end of the process !!!
15736 [] INFO 2023-11-04 07:15:45.053 TM1.Process Process “S. 10 Test of time value”: finished executing normally, elapsed time 0.00 seconds
15736 [] INFO 2023-11-04 07:15:45.053 TM1.Chore Chore “S. 10 test of time” time = 0.00 seconds
15736 [] INFO 2023-11-04 07:15:45.054 TM1.Chore Chore “S. 10 test of time” finished executing
Recommend to use Local time setting in chores, if you do not have servers in different time zones.
The line in log file for when you set the start time will always be in GMT time, like Registering chore: “S. 10 test of time” Start time: 2023/11/04 06:25:45 Frequency: 01:00:00:00, even do you have selected local server time in the chore and choose to start at 7:25 AM.
To setup a chore:
More Information:
https://exploringtm1.com/changing-tm1-server-log-time-zone-stamp/
https://www.ibm.com/docs/en/planning-analytics/2.0.0?topic=dtrf-timst
https://exploringtm1.com/date-and-time-functions-for-easy-date-manipulation/
https://tm1up.com/9-chores-in-tm1.html
How to set up Turbo Integrator Chores to run Advanced Scheduling