tcltrace::before-ns_log (private)

 tcltrace::before-ns_log cmd op

Defined in packages/acs-tcl/tcl/tcltrace-procs.tcl

Execute this proc before ns_log is called

Parameters:
cmd (required)
the full command as executed by Tcl
op (required)
the trace operation

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-tcl/tcl/tcltrace-init.tcl packages/acs-tcl/ tcl/tcltrace-init.tcl tcltrace::before-ns_log tcltrace::before-ns_log packages/acs-tcl/tcl/tcltrace-init.tcl->tcltrace::before-ns_log ds_comment ds_comment (public) tcltrace::before-ns_log->ds_comment parameter::get_from_package_key parameter::get_from_package_key (public) tcltrace::before-ns_log->parameter::get_from_package_key

Testcases:
No testcase defined.
Source code:
        set msg [join [lassign $cmd cmdname severity]]
        set severity [string totitle $severity]
        if {![info exists ::__log_severities]} {
            set ::__log_severities [::parameter::get_from_package_key  -package_key acs-tcl  -parameter TclTraceLogSeverities  -default ""]
        }
        if {$severity in $::__log_severities} {
            # we do not want i18n raw strings substituted via ds_comment.
            # Maybe we should add this substitution there....
            regsub -all -- {\#([a-zA-Z0-9._-]+)\#} $msg {\#\1\#} msg
            catch {ds_comment "$cmdname $severity $msg"}
        } else {
            #catch {ds_comment "ignore $severity $msg"}
        }
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: