TM1 Version 9.5.2 FP3.
In a TI Process, the ChoreQuit command was correctly executed, but the chore continued to run.
The chore contains 12 TI process steps, the error occured in the 4th TI process.
The tm1server.log contains an ERROR line that the TI process Execution was aborted by ChoreQuit() Function (see red line below).
However, the TI process that called the TI process that generated the error continued to run, as well as the remaining TI processes in the chore ran.
Any ideas why?
472 [] INFO 2014-01-03 21:20:27.029 TM1.Process Process "UNI - Dataload - Export Nightly Data" run from process "UNI - Export Nightly Data Call" by user "R*ADMIN - Over Night Full Process"
472 [] ERROR 2014-01-03 21:29:31.594 TM1.SQLAPI
472 [] INFO 2014-01-03 21:29:31.594 TM1.Process Process "UNI - Dataload - Export Nightly Data": finished executing normally, elapsed time 544.57 seconds
472 [] INFO 2014-01-03 21:29:31.594 TM1.Process Process "UNI - Dataload - Export Nightly Data" run from process "UNI - Export Nightly Data Call" by user "R*ADMIN - Over Night Full Process"
472 [] ERROR 2014-01-03 21:29:53.558 TM1.SQLAPI S1000[Oracle][ODBC][Ora]ORA-12170: TNS:Connect timeout occurred
472 [] ERROR 2014-01-03 21:29:53.558 TM1.SQLAPI E16) Cannot connect to ODBC data source "UNI-Oracle GL" S1000[Oracle][ODBC][Ora]ORA-12170: TNS:Connect timeout occurred
.
472 [] ERROR 2014-01-03 21:29:53.558 TM1.SQLAPI 08003[Microsoft][ODBC Driver Manager] Connection not open
472 [] ERROR 2014-01-03 21:29:53.558 TM1.Process Process "UNI - Dataload - Export Nightly Data": : Execution was aborted. Error file: <TM1ProcessError_20140104022953_UNI - Dataload - Export Nightly Data.log>
472 [] INFO 2014-01-03 21:29:53.558 TM1.Process Process "UNI - Export Nightly Data Error Notify" run from process "UNI - Export Nightly Data Call" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:29:53.558 TM1.Process Process "ADMIN - Send Generic Email" run from process "UNI - Export Nightly Data Error Notify" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:29:53.574 TM1.Process Process "ADMIN - Send Generic Email": finished executing normally, elapsed time 0.02 seconds
472 [] INFO 2014-01-03 21:29:53.574 TM1.Process Process "UNI - Export Nightly Data Error Notify": finished executing normally, elapsed time 0.02 seconds
472 [] ERROR 2014-01-03 21:29:53.574 TM1.Process Process "UNI - Export Nightly Data Call": : Execution was aborted by ChoreQuit() Function.472 [] INFO 2014-01-03 21:29:53.574 TM1.Process Process "UNI - Loop Delete Nightly Data Files" run from process "ADMIN - OVERNIGHT FULL PROCESS" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:29:54.151 TM1.Process Process "UNI - Loop Delete Nightly Data Files": finished executing normally, elapsed time 0.58 seconds
472 [] INFO 2014-01-03 21:29:54.151 TM1.Process Process "UNI - Copy Nightly Data Files" run from process "ADMIN - OVERNIGHT FULL PROCESS" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:31:36.830 TM1.Process Process "UNI - Copy Nightly Data Files": finished executing normally, elapsed time 102.68 seconds
472 [] INFO 2014-01-03 21:31:36.830 TM1.Process Process "UNI-General Zero Out Month (Year Scen Book)" run from process "ADMIN - OVERNIGHT FULL PROCESS" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:32:44.737 TM1.Process Process "UNI - General Zero Out Month (Year Scen Book)": finished executing normally, elapsed time 67.91 seconds
472 [] INFO 2014-01-03 21:32:44.737 TM1.Process Process "UNI - Dataload - Import Nightly Data Call" run from process "ADMIN - OVERNIGHT FULL PROCESS" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:32:44.737 TM1.Process Process "UNI - Dataload - Import Nightly Data" run from process "UNI - Dataload - Import Nightly Data Call" by user "R*ADMIN - Over Night Full Process"
472 [] INFO 2014-01-03 21:32:45.392 TM1.Process Process "UNI - Dataload - Import Nightly Data": finished executing normally, elapsed time 0.65 seconds
ChoreQuit executed, but chore continued to run
-
- Community Contributor
- Posts: 128
- Joined: Wed Oct 14, 2009 7:46 am
- OLAP Product: TM1
- Version: 9.4
- Excel Version: 11
- Location: London
Re: ChoreQuit executed, but chore continued to run
The error message you get is as expected:
If you don't want to induce an error message, you may want to consider controlling your process flow via some kind of metadata cube with flags to specify when to run each process.
I am guessing that your chore runs a TI process that then runs some nested processes, and it is one of these nested processes where the ChoreQuit function is being executed? If your chore is simply a list of processes run in sequence within the chore, then the ChoreQuit should prevent subsequent processes from being run. You will however still get an error message as per the documentation.ChoreQuit
This is a TM1 TurboIntegrator function, valid only in TurboIntegrator processes.
This function causes the immediate termination of a chore. It can be called from any process within a chore.
When a process encounters the ChoreQuit function, the current chore is terminated with an error status, and a message is written to the server log file indicating that ChoreQuit was called to terminate the chore.
Syntax
ChoreQuit;
Arguments
None.
If you don't want to induce an error message, you may want to consider controlling your process flow via some kind of metadata cube with flags to specify when to run each process.
-
- Posts: 54
- Joined: Tue May 08, 2012 3:58 pm
- OLAP Product: TM1
- Version: 9.5.2 FP2
- Excel Version: Excel 2007
Re: ChoreQuit executed, but chore continued to run
In this situation, I do want the ChoreQuit to stop the current TI process, and stop the Chore as well.
The TI process that encountered the error, and executed the ChoreQuit command was indeed executed by another TI process within a loop.
When the ChoreQuit command was executed, the looping did stop, but the TI commands in the controlling TI process after that loop did continue to execute, and after that TI process, the remaining Chore steps also executed.
I was expecting the Chore to have been stopped immediately by the ChoreQuit command.
The TI process that encountered the error, and executed the ChoreQuit command was indeed executed by another TI process within a loop.
When the ChoreQuit command was executed, the looping did stop, but the TI commands in the controlling TI process after that loop did continue to execute, and after that TI process, the remaining Chore steps also executed.
I was expecting the Chore to have been stopped immediately by the ChoreQuit command.
-
- Community Contributor
- Posts: 128
- Joined: Wed Oct 14, 2009 7:46 am
- OLAP Product: TM1
- Version: 9.4
- Excel Version: 11
- Location: London
Re: ChoreQuit executed, but chore continued to run
Unfortunately the function isn't "clever enough" to do that for nested processes within the chore. When I HAVE to use a chore, generally I create it with 1 master process and then use flagging to run the nested processes. An example explaining how to use a control cube can be found here:
http://www.tm1forum.com/viewtopic.php?f=3&t=9715
Instead of using the ChoreQuit function, I would suggest just nesting each TI process call in an IF statement, so you don't create the errors in the log file.
http://www.tm1forum.com/viewtopic.php?f=3&t=9715
Instead of using the ChoreQuit function, I would suggest just nesting each TI process call in an IF statement, so you don't create the errors in the log file.