We want the server to log the name of the Stored Process being executed. We've found that the App.SASSTP.RQ logger at the INFO level logs the file being executed by the stored process as well as the SAS Log, but doesn't appear to contain the Name of the Stored Process that was called.
1.) Assuming SAS Logs this information somewhere, which logger and at what level we need to configure Log4SAS in order to capture the Stored Process Name?
2.) Is there any documentation on the various Loggers that we can reference to understand what events they log?
Note: We are on 9.4 M3.
A few examples of loggers and levels that include the Stored Process name (and path):
2018-09-29T11:14:56,730 INFO [00000742] (App.SASSTP.RQ.LOG) 8:sasdemo - _PROGRAM=/Products/SAS Intelligence Platform/Samples/Sample: Hello World 2018-09-29T11:24:57,263 DEBUG [00000030] (App.SASXSTP) :sassrv - [00000004] STPXMVA Input arg: '_program' = /Products/SAS Intelligence Platform/Samples/Sample: Hello World 2018-09-29T11:24:57,275 INFO [00000008] (App.Program) 12:sasdemo - _PROGRAM=/Products/SAS Intelligence Platform/Samples/Sample: Hello World
... you may also want to add some log filter config to limit the output to what you want.
I assume that you are wanting this from outside the stored process itself e.g. audit logging? If the stored process wants to know what its own name/path is it can just use &_PROGRAM macro variable.
I assume you are familiar with the SAS® 9.4 Logging: Configuration and Programming Reference book. There is some very high level doc on the high level loggers but I have found you need to essentially discover the lower level loggers for yourself.
When I want to find log messages of interest I add the %c conversion character (logger name) into the pattern, turn everything up to debug/trace (in a playpen environment) run the process of interest, search for familiar text to see what gets logged where and at what level. You can then turn logging down to a more realistic level and add in the specific config to get what you need.
A few examples of loggers and levels that include the Stored Process name (and path):
2018-09-29T11:14:56,730 INFO [00000742] (App.SASSTP.RQ.LOG) 8:sasdemo - _PROGRAM=/Products/SAS Intelligence Platform/Samples/Sample: Hello World 2018-09-29T11:24:57,263 DEBUG [00000030] (App.SASXSTP) :sassrv - [00000004] STPXMVA Input arg: '_program' = /Products/SAS Intelligence Platform/Samples/Sample: Hello World 2018-09-29T11:24:57,275 INFO [00000008] (App.Program) 12:sasdemo - _PROGRAM=/Products/SAS Intelligence Platform/Samples/Sample: Hello World
... you may also want to add some log filter config to limit the output to what you want.
I assume that you are wanting this from outside the stored process itself e.g. audit logging? If the stored process wants to know what its own name/path is it can just use &_PROGRAM macro variable.
The App.SASSTP.RQ.LOG seems to have the information I need. Thank you,
No problem and thanks for marking it solved.
I think that logger gives you the whole SAS log so if that's too much info then have a look at logging Filters and the FilteringAppender to cut it down to just the message(s) you are interested in.
The SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment.
SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.
Find more tutorials on the SAS Users YouTube channel.