Skip to content

Commit

Permalink
HPCC-30912 Ensure configured log detail is used.
Browse files Browse the repository at this point in the history
If no workunit based logging detail was specified, the jlog
default level was being used, instead of the configured level.

Signed-off-by: Jake Smith <[email protected]>
  • Loading branch information
jakesmith committed Nov 23, 2023
1 parent e09e412 commit fd4c81d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion thorlcr/master/thgraphmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,8 @@ void CJobManager::run()
addTimeStamp(w, wfid, graphName, StWhenDequeued);
}

unsigned maxLogDetail = workunit->getDebugValueInt("maxlogdetail", DefaultDetail);
unsigned defaultConfigLogLevel = getComponentConfigSP()->getPropInt("logging/@detail", DefaultDetail);
unsigned maxLogDetail = workunit->getDebugValueInt("maxlogdetail", defaultConfigLogLevel);
ILogMsgFilter *existingLogHandler = queryLogMsgManager()->queryMonitorFilter(logHandler);
dbgassertex(existingLogHandler);
verifyex(queryLogMsgManager()->changeMonitorFilterOwn(logHandler, getCategoryLogMsgFilter(existingLogHandler->queryAudienceMask(), existingLogHandler->queryClassMask(), maxLogDetail)));
Expand Down
3 changes: 2 additions & 1 deletion thorlcr/slave/slavmain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1880,7 +1880,8 @@ class CJobListener : public CSimpleInterface
StringBuffer user;
workUnitInfo->getProp("user", user);

unsigned maxLogDetail = workUnitInfo->getPropInt("Debug/maxlogdetail", DefaultDetail);
unsigned defaultConfigLogLevel = getComponentConfigSP()->getPropInt("logging/@detail", DefaultDetail);
unsigned maxLogDetail = workUnitInfo->getPropInt("Debug/maxlogdetail", defaultConfigLogLevel);
ILogMsgFilter *existingLogHandler = queryLogMsgManager()->queryMonitorFilter(logHandler);
dbgassertex(existingLogHandler);
verifyex(queryLogMsgManager()->changeMonitorFilterOwn(logHandler, getCategoryLogMsgFilter(existingLogHandler->queryAudienceMask(), existingLogHandler->queryClassMask(), maxLogDetail)));
Expand Down

0 comments on commit fd4c81d

Please sign in to comment.