Page 1 of 1

Programmatic control over logging in TI / Chores

Posted: Tue Mar 18, 2014 10:04 pm
by Steve Rowe
I'd like to be able to conditionally turn TI logging in the TM1 message log off or on a case by case basis in the TI itself.

We are using PI to export and load data using 20 chores that are scheduled to run every 30 seconds. These chores only do work around 8 times a day when other TIs interacts with a schedule cube set various flags that indicate to the chores that there is work to do. This works v well and we are able to rapidly process data and minimise the read lock when loading data into the cube. We have not been able to note a performance down side to having the chores set-up like this.

Of course having 20 chores running every 30 seconds means that the message log fills up very quickly and it becomes very hard to impossible to use the message log, especially if we have to activate any enhanced DEBUG logging.

So in the TI that underlies the 20 chores I'd like to be able to only activate the logging when the TI reaches the point that it determines that is has work to do.

Cheers,
Steve R

Re: Programmatic control over logging in TI / Chores

Posted: Fri Mar 21, 2014 9:48 pm
by Alan Kirk
Steve Rowe wrote:I'd like to be able to conditionally turn TI logging in the TM1 message log off or on a case by case basis in the TI itself.
Agreed with this one as well; the logs are way too chatty (charitable description) / bloated (accurate description) in the newer versions. While we're at it I'd like to expand this one step further with a TI variable named something like WriteErrorLogsOnlyInErroringProcess.

When I'm calling process execution, particularly when the calls are a few levels deep, I really don't need all of the:

Code: Select all

Error: Prolog procedure line (97):  Errors occurred during execution of process "MyCalledProcess".  Check error log file for that process for more details
logs. It bloats my log files folder, and worse than that it obscures the presence of the files that really do contain the relevant information.

I understand why the messages are written and the reason isn't brain-dead, but it's still something that isn't always useful (in fact I've never found it useful) and should certainly be able to be turned off so that when you look in the log directory, all you see are the error logs that contain the error information, and not a profusion of logs that merely point you to other logs. Or, to put it another way, "Don't bore us, get to the chorus".

Re: Programmatic control over logging in TI / Chores

Posted: Wed Dec 17, 2014 9:01 am
by John Zhang
Exactly what we need in our environment as well. Meanwhile is there any workarounds available before TM1 evolves to that capability? Thanks.

Re: Programmatic control over logging in TI / Chores

Posted: Wed Dec 17, 2014 12:51 pm
by jim wood
I can understand why they've done what they have this, but for me you should have the ability to control all levels of logging. I get the fact that's it's handy for bugs or identifying process issues but the level of logging needed can chnge per user company, so the level of logging should reflect this.

Re: Programmatic control over logging in TI / Chores

Posted: Wed Dec 17, 2014 4:15 pm
by BrianL
jim wood wrote:I can understand why they've done what they have this, but for me you should have the ability to control all levels of logging.
You can set TM1.Process=OFF to disable these messages entirely.

I'm not sure how a TI could selectively enable/disable log messages that have already been output (Process "foo" executed) since that message is logged BEFORE the TI script has actually started executing.