Skip to content

Commit

Permalink
Feat[MWC]: retrieve bslsLogSeverityThreshold from config
Browse files Browse the repository at this point in the history
Signed-off-by: Anton Pryakhin <[email protected]>
  • Loading branch information
waldgange committed Oct 15, 2024
1 parent 70bfe34 commit 4f6830c
Showing 1 changed file with 7 additions and 14 deletions.
21 changes: 7 additions & 14 deletions src/groups/mwc/mwctsk/mwctsk_logcontroller.h
Original file line number Diff line number Diff line change
Expand Up @@ -525,20 +525,13 @@ int LogControllerConfig::fromObj(bsl::ostream& errorDescription,
}

ball::Severity::Level bslsSeverityAsBal = ball::Severity::e_ERROR;
// TODO: enforcing 'obj' to have 'bslsLogSeverityThreshold' accessor is a
// backward incompatible change from build perspective, and will require a
// bulk promotion of dependents, which can be tackled later. For now, we
// just assume a log severity level of 'ERROR'.
// if (ball::SeverityUtil::fromAsciiCaseless(
// &bslsSeverityAsBal,
// obj.bslsLogSeverityThreshold().c_str()) !=
// 0) {
// errorDescription << "Invalid value for 'bslsLogSeverityThreshold'
// ('"
// << obj.bslsLogSeverityThreshold() << "')";
// return -1; //
// RETURN
// }
if (ball::SeverityUtil::fromAsciiCaseless(
&bslsSeverityAsBal,
obj.bslsLogSeverityThreshold().c_str()) != 0) {
errorDescription << "Invalid value for 'bslsLogSeverityThreshold'('"
<< obj.bslsLogSeverityThreshold() << "')";
return -1; // RETURN
}
d_bslsLogSeverityThreshold = LogControllerConfig::balToBslsLogLevel(
bslsSeverityAsBal);

Expand Down

0 comments on commit 4f6830c

Please sign in to comment.