Allow first argument to logger to be string or subroutine
Bug #1824181 reported by
John Merriam
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenSRF |
Fix Released
|
Medium
|
Unassigned | ||
3.0 |
Fix Released
|
Medium
|
Unassigned |
Bug Description
This simple change allows the $msg passed to _log_message in Logger.pm to be either a regular string or a delayed exec subroutine. This is in reaction to LP1823338 where a slow debug logging statement was slowing down SIP checkins even though debug logging was not turned on.
With this change you can take this:
$log->debug(
and change it to this:
$log->debug(
and then that slow debug logging line will not be executed unless debug logging is turned on.
Branch to follow.
Changed in opensrf: | |
status: | New → Confirmed |
importance: | Undecided → Medium |
Changed in opensrf: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
OpenSRF branch is working/ user/jmerriam/ allow_log_ subs: /git.evergreen- ils.org/ ?p=working/ OpenSRF. git;a=shortlog; h=refs/ heads/user/ jmerriam/ allow_log_ subs
https:/