Index: openacs-4/packages/acs-bootstrap-installer/acs-bootstrap-installer.info =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-bootstrap-installer/acs-bootstrap-installer.info,v diff -u -r1.46 -r1.47 --- openacs-4/packages/acs-bootstrap-installer/acs-bootstrap-installer.info 3 Sep 2024 15:37:30 -0000 1.46 +++ openacs-4/packages/acs-bootstrap-installer/acs-bootstrap-installer.info 28 Oct 2024 16:04:30 -0000 1.47 @@ -9,7 +9,7 @@ f t - + Don Baccus Bootstraps an OpenACS installation. 2024-09-02 @@ -18,7 +18,7 @@ GPL 3 - + Index: openacs-4/packages/acs-bootstrap-installer/bootstrap.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-bootstrap-installer/bootstrap.tcl,v diff -u -r1.37 -r1.38 --- openacs-4/packages/acs-bootstrap-installer/bootstrap.tcl 23 Oct 2024 10:41:13 -0000 1.37 +++ openacs-4/packages/acs-bootstrap-installer/bootstrap.tcl 28 Oct 2024 16:04:31 -0000 1.38 @@ -174,7 +174,7 @@ # packages have had their Tcl libraries loaded. apm_load_packages -load_libraries_p 0 -load_queries_p 0 -packages acs-tcl - if { ![nsv_exists rp_properties request_count] } { + if { ![nsv_exists rp_properties rp_initialized] } { # security-init.tcl has not been invoked, so it's safe to say that the # core has not been properly initialized and the server will probably # fail catastrophically. Index: openacs-4/packages/acs-developer-support/acs-developer-support.info =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-developer-support/acs-developer-support.info,v diff -u -r1.27 -r1.28 --- openacs-4/packages/acs-developer-support/acs-developer-support.info 3 Sep 2024 15:37:33 -0000 1.27 +++ openacs-4/packages/acs-developer-support/acs-developer-support.info 28 Oct 2024 16:04:31 -0000 1.28 @@ -8,19 +8,19 @@ t ds - + Lars Pind Profiling for requests including database timing information. 2024-09-02 OpenACS - Developer support stores timing and other logged information for requests + Developer support stores timing and other logged information for requests to support debugging and tuning and supports user switching and a Tcl Shell to invoke arbitrary tcl code on the server. 3 - - - + + + Index: openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl,v diff -u -r1.65 -r1.66 --- openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl 3 Sep 2024 15:37:33 -0000 1.65 +++ openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl 28 Oct 2024 16:04:31 -0000 1.66 @@ -402,7 +402,7 @@ } if { ![info exists ::ad_conn(request)] } { - set ::ad_conn(request) [nsv_incr rp_properties request_count] + set ::ad_conn(request) [ns_conn id] } nsv_lappend ds_request $::ad_conn(request).$name {*}$args } @@ -450,7 +450,7 @@ ns_log "Debug" "Swept developer support information for [array size kill_requests] requests ($kill_count nsv elements)" } -ad_proc -private ds_trace_filter { conn args why } { +ad_proc -private ds_trace_filter { why args } { Adds developer-support information about the end of sessions. } { if { [ds_enabled_p] && [ds_collection_enabled_p] } { Index: openacs-4/packages/acs-tcl/acs-tcl.info =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/acs-tcl.info,v diff -u -r1.97 -r1.98 --- openacs-4/packages/acs-tcl/acs-tcl.info 16 Oct 2024 09:21:21 -0000 1.97 +++ openacs-4/packages/acs-tcl/acs-tcl.info 28 Oct 2024 16:04:31 -0000 1.98 @@ -9,7 +9,7 @@ f t - + OpenACS The Kernel Tcl API library. 2024-09-02 @@ -18,8 +18,8 @@ GPL version 2 3 - - + + Index: openacs-4/packages/acs-tcl/tcl/admin-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/admin-procs.tcl,v diff -u -r1.32 -r1.33 --- openacs-4/packages/acs-tcl/tcl/admin-procs.tcl 11 Sep 2024 06:15:48 -0000 1.32 +++ openacs-4/packages/acs-tcl/tcl/admin-procs.tcl 28 Oct 2024 16:04:31 -0000 1.33 @@ -8,7 +8,7 @@ } -ad_proc -public ad_restrict_to_https {conn args why} { +ad_proc -public ad_restrict_to_https {args why} { Redirects user to HTTPS. @author Allen Pulsifer (pulsifer@mediaone.net) Index: openacs-4/packages/acs-tcl/tcl/deprecated-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/deprecated-procs.tcl,v diff -u -r1.31 -r1.32 --- openacs-4/packages/acs-tcl/tcl/deprecated-procs.tcl 11 Sep 2024 06:15:48 -0000 1.31 +++ openacs-4/packages/acs-tcl/tcl/deprecated-procs.tcl 28 Oct 2024 16:04:31 -0000 1.32 @@ -26,7 +26,107 @@ } ns_log notice "deprecated-procs: load deprecated code" +ad_proc -deprecated rp_getform {} { + This proc is a simple wrapper around AOLserver's standard ns_getform + proc, that will create the form if it doesn't exist, so that you + can then add values to that form. This is useful in conjunction + with rp_internal_redirect to redirect to a different page with + certain query variables set. + + DEPRECATED: modern ns_getform from NaviServer will never return + the empty string, assuming that we are in a connection. When we + are not in a connection, it makes little sense that we set request + variables. + + @see ns_getform + + @author Lars Pind (lars@pinds.com) + @creation-date August 20, 2002 + + @return the form ns_set, just like ns_getform, except it will + always be nonempty. + +} { + # The form may not exist, if there's nothing in it + if { [ns_getform] ne "" } { + # It's there + return [ns_getform] + } { + # It doesn't exist, create a new one + + # This is the magic global Tcl variable that AOLserver uses + # to store the ns_set that contains the query args or form. + global _ns_form + + # Simply create a new ns_set and store it in the global _ns_set variable + set _ns_form [ns_set create] + return $_ns_form + } +} + +ad_proc -deprecated rp_form_put { name value } { + + This proc adds a query variable to AOLserver's internal ns_getform + form, so that it'll be picked up by ad_page_contract and other procs + that look at the query variables or form supplied. This is useful + when you do an rp_internal_redirect to a new page, and you want to + feed that page with certain query variables. + + Note that the variable will just be appended to the form ns_set + which may not be what you want, if it exists already you will + now have two entries in the ns_set which may cause ad_page_contract to + break. Also, only simple variables may be added, not arrays. + + DEPRECATED: this proc is a trivial wrapper over NaviServer + functionalities. One should use the native api directly. + + @see ns_getform + @see ns_set + + @author Lars Pind (lars@pinds.com) + @creation-date August 20, 2002 + + @return the form ns_set, in case you're interested. Mostly you will want to discard the result. + +} { + set form [ns_getform] + ns_set put $form $name $value + return $form +} + + +ad_proc -deprecated rp_form_update { name value } { + + Identical to rp_form_put, but uses ns_set update instead. + + DEPRECATED: this proc is a trivial wrapper over NaviServer + functionalities. One should use the native api directly. + + @see ns_getform + @see ns_set + + @return the form ns_set, in case you're interested. Mostly you will want to discard the result. + +} { + set form [ns_getform] + ns_set update $form $name $value + return $form +} + +ad_proc -deprecated root_of_host {host} { + + Maps a hostname to the corresponding subdirectory. + + DEPRECATED: this proc does not comply with OpenACS naming + convention. + + @see acs::root_of_host + +} { + return [acs::root_of_host $host] +} + ad_proc -deprecated ad_approval_system_inuse_p {} { Returns 1 if the system is configured to use and approval system. Index: openacs-4/packages/acs-tcl/tcl/request-processor-init.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/request-processor-init.tcl,v diff -u -r1.23 -r1.24 --- openacs-4/packages/acs-tcl/tcl/request-processor-init.tcl 11 Sep 2024 06:15:48 -0000 1.23 +++ openacs-4/packages/acs-tcl/tcl/request-processor-init.tcl 28 Oct 2024 16:04:31 -0000 1.24 @@ -12,7 +12,7 @@ # set ::acs::kernel_id [ad_acs_kernel_id] -if {[nsv_exists rp_properties request_count] != 0} { +if {[ns_ictl epoch] > 0} { # # This is a re-init. There is no need, to rerun the code # below. Setting e.g. filters multiple times might have unwanted @@ -201,7 +201,7 @@ # Set a flag for bootststrap that at least, the request processor has # done all essential initialization # -nsv_set rp_properties request_count 0 +nsv_set rp_properties rp_initialized 1 # Local variables: # mode: tcl Index: openacs-4/packages/acs-tcl/tcl/request-processor-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/request-processor-procs.tcl,v diff -u -r1.156 -r1.157 --- openacs-4/packages/acs-tcl/tcl/request-processor-procs.tcl 8 Oct 2024 15:20:57 -0000 1.156 +++ openacs-4/packages/acs-tcl/tcl/request-processor-procs.tcl 28 Oct 2024 16:04:31 -0000 1.157 @@ -80,93 +80,6 @@ ad_conn -set file $saved_file } -ad_proc -deprecated rp_getform {} { - - This proc is a simple wrapper around AOLserver's standard ns_getform - proc, that will create the form if it doesn't exist, so that you - can then add values to that form. This is useful in conjunction - with rp_internal_redirect to redirect to a different page with - certain query variables set. - - DEPRECATED: modern ns_getform from NaviServer will never return - the empty string, assuming that we are in a connection. When we - are not in a connection, it makes little sense that we set request - variables. - - @see ns_getform - - @author Lars Pind (lars@pinds.com) - @creation-date August 20, 2002 - - @return the form ns_set, just like ns_getform, except it will - always be nonempty. - -} { - # The form may not exist, if there's nothing in it - if { [ns_getform] ne "" } { - # It's there - return [ns_getform] - } { - # It doesn't exist, create a new one - - # This is the magic global Tcl variable that AOLserver uses - # to store the ns_set that contains the query args or form. - global _ns_form - - # Simply create a new ns_set and store it in the global _ns_set variable - set _ns_form [ns_set create] - return $_ns_form - } -} - -ad_proc -deprecated rp_form_put { name value } { - - This proc adds a query variable to AOLserver's internal ns_getform - form, so that it'll be picked up by ad_page_contract and other procs - that look at the query variables or form supplied. This is useful - when you do an rp_internal_redirect to a new page, and you want to - feed that page with certain query variables. - - Note that the variable will just be appended to the form ns_set - which may not be what you want, if it exists already you will - now have two entries in the ns_set which may cause ad_page_contract to - break. Also, only simple variables may be added, not arrays. - - DEPRECATED: this proc is a trivial wrapper over NaviServer - functionalities. One should use the native api directly. - - @see ns_getform - @see ns_set - - @author Lars Pind (lars@pinds.com) - @creation-date August 20, 2002 - - @return the form ns_set, in case you're interested. Mostly you will want to discard the result. - -} { - set form [ns_getform] - ns_set put $form $name $value - return $form -} - -ad_proc -deprecated rp_form_update { name value } { - - Identical to rp_form_put, but uses ns_set update instead. - - DEPRECATED: this proc is a trivial wrapper over NaviServer - functionalities. One should use the native api directly. - - @see ns_getform - @see ns_set - - @return the form ns_set, in case you're interested. Mostly you will want to discard the result. - -} { - set form [ns_getform] - ns_set update $form $name $value - return $form -} - ad_proc -private rp_registered_proc_info_compare { info1 info2 } { A comparison predicate for registered procedures, returning -1, 0, @@ -225,7 +138,7 @@ nsv_lappend rp_registered_procs . $proc_info } -ad_proc -private rp_invoke_filter { conn filter_info why } { +ad_proc -private rp_invoke_filter { why filter_info } { Invokes the filter described in $argv, writing an error message to the browser if it fails (unless kind is trace). @@ -235,12 +148,12 @@ lassign $filter_info filter_index debug_p arg_count proc arg rp_debug -debug $debug_p "Invoking $why filter $proc" + #ns_log notice "RP_INVOKE_FILTER " filter_info <$filter_info> why <$why> proc <$proc> arg_count $arg_count switch -- $arg_count { 0 { set cmd $proc } - 1 { set cmd [list $proc $why] } - 2 { set cmd [list $proc $conn $why] } - default { set cmd [list $proc $conn $arg $why] } + 1 { set cmd [list $proc $why ] } + default { set cmd [list $proc $arg $why ] } } set errno 0 @@ -286,7 +199,7 @@ return $result } -ad_proc -private rp_invoke_proc { conn argv } { +ad_proc -private rp_invoke_proc { argv } { Invokes a registered procedure. @@ -300,7 +213,7 @@ switch -- $arg_count { 0 { set cmd $proc } 1 { set cmd [list $proc {*}$arg] } - default { set cmd [list $proc $conn {*}$arg] } + default { set cmd [list $proc {*}$arg] } } ad_try -auto_abort=false { @@ -566,15 +479,7 @@ sec_handler_reset ad_conn -reset - if {[ns_info name] eq "NaviServer"} { - # ns_conn id the internal counter by AOLserver 4.5 and - # NaviServer. The semantics of the counter were different in - # AOLserver 4.0, when we require at least AOLserver 4.5 the - # server test could go away. - ad_conn -set request [ns_conn id] - } else { - ad_conn -set request [nsv_incr rp_properties request_count] - } + ad_conn -set request [ns_conn id] ad_conn -set user_id 0 ad_conn -set start_clicks [clock clicks -microseconds] @@ -1977,19 +1882,6 @@ namespace eval ::acs {} -ad_proc -deprecated root_of_host {host} { - - Maps a hostname to the corresponding subdirectory. - - DEPRECATED: this proc does not comply with OpenACS naming - convention. - - @see acs::root_of_host - -} { - return [acs::root_of_host $host] -} - ad_proc acs::root_of_host {host} { Maps a hostname to the corresponding subdirectory. @@ -2063,27 +1955,6 @@ } - -if {[ns_info name] eq "NaviServer"} { - # this is written for NaviServer 4.99.1 or newer - foreach filter {rp_filter rp_resources_filter rp_request_denied_filter} { - set cmd ${filter}_aolserver - if {[namespace which $cmd] ne ""} {rename $cmd ""} - rename $filter $cmd - proc $filter {why} "$cmd \$why" - } - - set cmd rp_invoke_filter_conn - if {[namespace which $cmd] ne ""} {rename $cmd ""} - rename rp_invoke_filter $cmd - proc rp_invoke_filter { why filter_info} "$cmd _ \$filter_info \$why" - - set cmd rp_invoke_proc_conn - if {[namespace which $cmd] ne ""} {rename $cmd ""} - rename rp_invoke_proc $cmd - proc rp_invoke_proc { argv } "$cmd _ \$argv" -} - #ad_proc -private rp_debug { { -debug f } { -ns_log_level notice } string } { ns_log notice "RP: $string"} #