acs::try_cache (private)
acs::try_cache cache operation [ args... ]
Defined in packages/acs-tcl/tcl/acs-cache-procs.tcl
Function to support caching during bootstrap. When the provided cache exists, then use it for caching, otherwise perform uncalled call. This function is made intentionally private, since this should only be required during bootstrapping. It does not make sense to wrap arbitrary caching calls with this function.
- Parameters:
- cache (required)
- operation (required)
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: if { [namespace which $cache] ne "" && [$cache info lookup methods $operation] ne "" } { return [uplevel 1 [list $cache $operation {*}$args]] } else { # # Complain only, when # a) not during initial install, and # b) if this is not during startup of an installed version # set complain_p [expr {[ns_ictl epoch] > 0 && [nsv_names acs_installer] eq ""}] if {$operation eq "eval"} { nsf::parseargs {{-partition_key} {-expires} {-per_request:switch} key command} $args if {$complain_p} { ns_log warning "no cache $cache: need direct call $key $args" } #ns_log warning "no cache $cache: need direct call $key [info exists partition_key] <$command>" return [uplevel 1 $command] } if {$complain_p} { ns_log warning "no cache $cache: call ignored" } }XQL Not present: Generic, PostgreSQL, Oracle