nsmcp::cleanup (private)
nsmcp::cleanup
Defined in /usr/local/ns/tcl/nsmcp/examples/nsmcp-openacs-api-docs.tcl
Release nsmcp objects and resources associated with an interpreter.
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: variable temporary if {![info exists temporary]} { return } set objects $temporary unset temporary foreach object [lreverse [dict keys $objects]] { # A destroyed anonymous command name may already refer to a persistent # object. Only sweep the exact lifetime registered by RequestClass::new. # Old name-only entries from a definition reload cannot prove ownership. if {[::nsf::object::exists $object] && [::nsf::var::exists $object __nsmcpRequestLifetime] && [::nsf::var::set $object __nsmcpRequestLifetime] eq [dict get $objects $object]} { if {[catch { $object destroy }]} { if {[info commands ns_log] ne ""} { ns_log error "nsmcp: temporary object cleanup failed" } # Never return a potentially contaminated interpreter to pool. if {[info commands ns_ictl] ne ""} { ns_ictl markfordelete } } } }XQL Not present: Generic, PostgreSQL, Oracle