throttle_mod-procs.tcl

This file defines the following Objects and Classes: ::Counter[i], ::Users[i]

Location:
packages/xotcl-request-monitor/tcl/throttle_mod-procs.tcl

Procedures in this file

Detailed information

::Counter proc set_in_all_instances (public)

 ::Counter[i] set_in_all_instances var value

A helper function to set in all (direct or indirect) instances an instance variable to the same value. This is used here in combination with changing parameters

Parameters:
var (required)
value (required)

Testcases:
No testcase defined.

::Users proc active (public)

 ::Users[i] active [ -full ]

Return a list of lists containing information about current users. If the switch 'full' is used this list contains these users who have used the server within the monitoring time window (per default: 10 minutes). Otherwise, just a list of requesters (user_ids or peer addresses for unauthenticated requests) is returned. If "-full" is used for each requester the last peer address, the last timestamp, the number of hits, a list of values for the activity calculations and the number of ip-switches the user is returned. The activity calculations are performed on base of an exponential smoothing algorithm which is calculated through an aggregated value, a timestamp (in minutes) and the number of hits in the monitored time window.

Switches:
-full (optional)
Returns:
list with detailed user info

Testcases:
No testcase defined.

::Users proc hits (public)

 ::Users[i] hits uid
Parameters:
uid (required)
request key
Returns:
Number of hits by this user (in time window)

Testcases:
No testcase defined.

::Users proc last_pa (public)

 ::Users[i] last_pa uid
Parameters:
uid (required)
request key
Returns:
last peer address of the specified users

Testcases:
No testcase defined.

::Users proc nr_active (public)

 ::Users[i] nr_active
Returns:
number of active users (in time window)

Testcases:
No testcase defined.

::Users proc nr_authenticated (public)

 ::Users[i] nr_authenticated
Returns:
number of authenticated users (in time window)

Testcases:
No testcase defined.

::Users proc nr_users_time_window (public)

 ::Users[i] nr_users_time_window
Returns:
number of different IP addresses and authenticated users (in time window)

Testcases:
No testcase defined.

::Users proc user_is_active (public)

 ::Users[i] user_is_active uid
Parameters:
uid (required)
Returns:
boolean value whether user is active

Testcases:
No testcase defined.

::throttle Class ::Counter (public)

 ::xotcl::Class Class[i]

Testcases:
No testcase defined.

::throttle Class ::Users (public)

 ::xotcl::Class Class[i]

Testcases:
No testcase defined.

throttle_mod::unmap_pool (private)

 throttle_mod::unmap_pool [ -pool pool ] [ -ms ms ] method url

Function within throttle monitor thread for registering pool unmapping requests after a specified time. This function has to run in this thread to be able to use "::after".

Switches:
-pool (optional, defaults to "slow")
-ms (optional)
Parameters:
method (required)
url (required)

Partial Call Graph (max 5 caller/called nodes):

Testcases:
No testcase defined.

xo::pool_remap_watchdog (private)

 xo::pool_remap_watchdog [ -maxWaiting maxWaiting ] \
    [ -maxRunning maxRunning ]

Watchdoc function to ensure liveliness of the server. This watchdog checks every minute the running jobs and maps very slow requests to the slow pool (if configured) to avoid that the default pool is getting filled up with more stuck requests. The watchdog is managed via an ad_schedule_proc started from the init-procs.

Switches:
-maxWaiting (optional, defaults to "10")
-maxRunning (optional, defaults to "100")

Partial Call Graph (max 5 caller/called nodes):
acs_mail_lite::send acs_mail_lite::send (public) ad_host_administrator ad_host_administrator (public) ad_system_name ad_system_name (public) ad_system_owner ad_system_owner (public) ad_url ad_url (public) xo::pool_remap_watchdog xo::pool_remap_watchdog xo::pool_remap_watchdog->acs_mail_lite::send xo::pool_remap_watchdog->ad_host_administrator xo::pool_remap_watchdog->ad_system_name xo::pool_remap_watchdog->ad_system_owner xo::pool_remap_watchdog->ad_url

Testcases:
No testcase defined.

xo::remap_pool (private)

 xo::remap_pool [ -threshold threshold ] [ -except except ] \
    [ -pool pool ] [ -runtime runtime ] method url

Function for dynamically managing connection pool mappings. When a connection pool "slow", is defined, and the query took longer than "threshold" seconds, and the URL is not 'except' list, then move this request to the "slow" pool.

Switches:
-threshold (optional, defaults to "3.0")
-except (optional, defaults to "/ /dotlrn/ /dotlrn")
-pool (optional, defaults to "slow")
-runtime (optional)
Parameters:
method (required)
url (required)

Partial Call Graph (max 5 caller/called nodes):
Object ::throttle Object ::throttle (public) xo::remap_pool xo::remap_pool Object ::throttle->xo::remap_pool xo::pool_remap_watchdog xo::pool_remap_watchdog (private) xo::pool_remap_watchdog->xo::remap_pool acs::icanuse acs::icanuse (public) xo::remap_pool->acs::icanuse

Testcases:
No testcase defined.

xo::request_monitor_user_info (private)

 xo::request_monitor_user_info key
Parameters:
key (required)

Partial Call Graph (max 5 caller/called nodes):
packages/xotcl-request-monitor/www/last-requests.tcl packages/xotcl-request-monitor/ www/last-requests.tcl xo::request_monitor_user_info xo::request_monitor_user_info packages/xotcl-request-monitor/www/last-requests.tcl->xo::request_monitor_user_info packages/xotcl-request-monitor/www/last100.tcl packages/xotcl-request-monitor/ www/last100.tcl packages/xotcl-request-monitor/www/last100.tcl->xo::request_monitor_user_info packages/xotcl-request-monitor/www/last101.tcl packages/xotcl-request-monitor/ www/last101.tcl packages/xotcl-request-monitor/www/last101.tcl->xo::request_monitor_user_info packages/xotcl-request-monitor/www/long-calls.tcl packages/xotcl-request-monitor/ www/long-calls.tcl packages/xotcl-request-monitor/www/long-calls.tcl->xo::request_monitor_user_info packages/xotcl-request-monitor/www/running.tcl packages/xotcl-request-monitor/ www/running.tcl packages/xotcl-request-monitor/www/running.tcl->xo::request_monitor_user_info acs_community_member_url acs_community_member_url (public) xo::request_monitor_user_info->acs_community_member_url person::get_person_info person::get_person_info (public) xo::request_monitor_user_info->person::get_person_info

Testcases:
No testcase defined.

xo::unmap_pool (private)

 xo::unmap_pool [ -pool pool ] method url
Switches:
-pool (optional, defaults to "slow")
Parameters:
method (required)
url (required)

Partial Call Graph (max 5 caller/called nodes):

Testcases:
No testcase defined.
[ show source ]