• Publicity: Public Only All

acs-developer-support-procs.tcl

Provides routines used to aggregate request/response information for debugging.

Location:
packages/acs-developer-support/tcl/acs-developer-support-procs.tcl
Created:
22 Apr 2000
Author:
Jon Salz

Procedures in this file

Detailed information

ds_add (public)

 ds_add name [ args... ]

Sets a developer-support property for the current request.

Parameters:
name

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_add_test ds_add_test (test acs-developer-support) ds_add ds_add test_ds_add_test->ds_add ds_collection_enabled_p ds_collection_enabled_p (public) ds_add->ds_collection_enabled_p ds_enabled_p ds_enabled_p (public) ds_add->ds_enabled_p ds_collect_connection_info ds_collect_connection_info (private) ds_collect_connection_info->ds_add ds_collect_db_call ds_collect_db_call (public) ds_collect_db_call->ds_add ds_comment ds_comment (public) ds_comment->ds_add ds_profile ds_profile (public) ds_profile->ds_add ds_trace_filter ds_trace_filter (private) ds_trace_filter->ds_add

Testcases:
ds_add_test

ds_adp_box_class (public)

 ds_adp_box_class

Return developer support adp box class on/off

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_adp_reveal_test ds_adp_reveal_test (test acs-developer-support) ds_adp_box_class ds_adp_box_class test_ds_adp_reveal_test->ds_adp_box_class ds_adp_reveal_enabled_p ds_adp_reveal_enabled_p (private) ds_adp_box_class->ds_adp_reveal_enabled_p

Testcases:
ds_adp_reveal_test

ds_adp_end_box (public)

 ds_adp_end_box [ -stub stub ]

Appends adp end box if the show toggle is true

Switches:
-stub (defaults to "$__adp_stub") (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 test_web_forum_edit web_forum_edit (test forums) ds_adp_end_box ds_adp_end_box test_web_forum_edit->ds_adp_end_box test_web_forum_new web_forum_new (test forums) test_web_forum_new->ds_adp_end_box test_web_forums_message_and_reply web_forums_message_and_reply (test forums) test_web_forums_message_and_reply->ds_adp_end_box template::adp_append_code template::adp_append_code (public) ds_adp_end_box->template::adp_append_code packages/acs-templating/tcl/tag-init.tcl packages/acs-templating/ tcl/tag-init.tcl packages/acs-templating/tcl/tag-init.tcl->ds_adp_end_box template::template_tag_include_helper template::template_tag_include_helper (private) template::template_tag_include_helper->ds_adp_end_box

Testcases:
web_forum_new, web_forum_edit, web_forums_message_and_reply

ds_adp_file_class (public)

 ds_adp_file_class

Return developer support adp file on/off

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_adp_reveal_test ds_adp_reveal_test (test acs-developer-support) ds_adp_file_class ds_adp_file_class test_ds_adp_reveal_test->ds_adp_file_class ds_adp_reveal_enabled_p ds_adp_reveal_enabled_p (private) ds_adp_file_class->ds_adp_reveal_enabled_p

Testcases:
ds_adp_reveal_test

ds_adp_output_class (public)

 ds_adp_output_class

Return developer support adp output on/off

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_adp_reveal_test ds_adp_reveal_test (test acs-developer-support) ds_adp_output_class ds_adp_output_class test_ds_adp_reveal_test->ds_adp_output_class ds_adp_reveal_enabled_p ds_adp_reveal_enabled_p (private) ds_adp_output_class->ds_adp_reveal_enabled_p

Testcases:
ds_adp_reveal_test

ds_adp_start_box (public)

 ds_adp_start_box [ -stub stub ]

Appends adp start box if the show toggle is true

Switches:
-stub (defaults to "$__adp_stub") (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 test_web_forum_edit web_forum_edit (test forums) ds_adp_start_box ds_adp_start_box test_web_forum_edit->ds_adp_start_box test_web_forum_new web_forum_new (test forums) test_web_forum_new->ds_adp_start_box test_web_forums_message_and_reply web_forums_message_and_reply (test forums) test_web_forums_message_and_reply->ds_adp_start_box template::adp_append_code template::adp_append_code (public) ds_adp_start_box->template::adp_append_code packages/acs-templating/tcl/tag-init.tcl packages/acs-templating/ tcl/tag-init.tcl packages/acs-templating/tcl/tag-init.tcl->ds_adp_start_box template::template_tag_include_helper template::template_tag_include_helper (private) template::template_tag_include_helper->ds_adp_start_box

Testcases:
web_forum_new, web_forum_edit, web_forums_message_and_reply

ds_collect_db_call (public)

 ds_collect_db_call db command statement_name sql start_time errno \
    error

Collects stats for a single database call

Parameters:
db
command
statement_name
sql
start_time
errno
error

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_add_test ds_add_test (test acs-developer-support) ds_collect_db_call ds_collect_db_call test_ds_add_test->ds_collect_db_call _ _ (public) ds_collect_db_call->_ db_bind_var_substitution db_bind_var_substitution (public) ds_collect_db_call->db_bind_var_substitution db_type db_type (public) ds_collect_db_call->db_type ds_add ds_add (public) ds_collect_db_call->ds_add ds_collection_enabled_p ds_collection_enabled_p (public) ds_collect_db_call->ds_collection_enabled_p Class ::acs::db::nsdb-postgresql Class ::acs::db::nsdb-postgresql (public) Class ::acs::db::nsdb-postgresql->ds_collect_db_call acs::db::nsdb-postgresql instproc {call acs_permission permission_p_recursive_array} acs::db::nsdb-postgresql instproc {call acs_permission permission_p_recursive_array} (public) acs::db::nsdb-postgresql instproc {call acs_permission permission_p_recursive_array}->ds_collect_db_call db_exec db_exec (public) db_exec->ds_collect_db_call db_exec_lob_oracle db_exec_lob_oracle (private) db_exec_lob_oracle->ds_collect_db_call db_exec_lob_postgresql db_exec_lob_postgresql (private) db_exec_lob_postgresql->ds_collect_db_call

Testcases:
ds_add_test

ds_collection_enabled_p (public)

 ds_collection_enabled_p

Returns whether we're collecting information about this request

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_collection_enabled_p ds_collection_enabled_p test_ds_features_enabled_test->ds_collection_enabled_p ad_conn ad_conn (public) ds_collection_enabled_p->ad_conn ds_add ds_add (public) ds_add->ds_collection_enabled_p ds_collect_connection_info ds_collect_connection_info (private) ds_collect_connection_info->ds_collection_enabled_p ds_collect_db_call ds_collect_db_call (public) ds_collect_db_call->ds_collection_enabled_p ds_get_db_command_info ds_get_db_command_info (private) ds_get_db_command_info->ds_collection_enabled_p ds_get_page_serve_time_ms ds_get_page_serve_time_ms (private) ds_get_page_serve_time_ms->ds_collection_enabled_p

Testcases:
ds_features_enabled_test

ds_comment (public)

 ds_comment value

Adds a comment to the developer-support information for the current request.

Parameters:
value

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_add_test ds_add_test (test acs-developer-support) ds_comment ds_comment test_ds_add_test->ds_comment ds_add ds_add (public) ds_comment->ds_add ds_enabled_p ds_enabled_p (public) ds_comment->ds_enabled_p tcltrace::before-ns_log tcltrace::before-ns_log (private) tcltrace::before-ns_log->ds_comment

Testcases:
ds_add_test

ds_database_enabled_p (public)

 ds_database_enabled_p

Returns true if developer-support database facilities are enabled.

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_database_enabled_p ds_database_enabled_p test_ds_features_enabled_test->ds_database_enabled_p ds_collect_db_call ds_collect_db_call (public) ds_collect_db_call->ds_database_enabled_p packages/acs-developer-support/lib/toolbar.tcl packages/acs-developer-support/ lib/toolbar.tcl packages/acs-developer-support/lib/toolbar.tcl->ds_database_enabled_p packages/acs-developer-support/www/index.tcl packages/acs-developer-support/ www/index.tcl packages/acs-developer-support/www/index.tcl->ds_database_enabled_p

Testcases:
ds_features_enabled_test

ds_enabled_p (public)

 ds_enabled_p
Returns:
true if developer-support facilities are enabled.

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_enabled_p ds_enabled_p test_ds_features_enabled_test->ds_enabled_p ds_add ds_add (public) ds_add->ds_enabled_p ds_collect_connection_info ds_collect_connection_info (private) ds_collect_connection_info->ds_enabled_p ds_collect_db_call ds_collect_db_call (public) ds_collect_db_call->ds_enabled_p ds_comment ds_comment (public) ds_comment->ds_enabled_p ds_get_db_command_info ds_get_db_command_info (private) ds_get_db_command_info->ds_enabled_p

Testcases:
ds_features_enabled_test

ds_init (public)

 ds_init

Perform setup for the developer support for a single request. We save the state in global variables to avoid highly redundant computations (up to 50 times per page on openacs.org)

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_init ds_init test_ds_features_enabled_test->ds_init ds_collection_enabled_p ds_collection_enabled_p (public) ds_init->ds_collection_enabled_p ds_enabled_p ds_enabled_p (public) ds_init->ds_enabled_p ds_profiling_enabled_p ds_profiling_enabled_p (public) ds_init->ds_profiling_enabled_p ds_show_p ds_show_p (public) ds_init->ds_show_p rp_serve_concrete_file rp_serve_concrete_file (public) rp_serve_concrete_file->ds_init

Testcases:
ds_features_enabled_test

ds_link (public)

 ds_link

Returns the "Developer Information" link in a right-aligned table, if enabled.

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_link_test ds_link_test (test acs-developer-support) ds_link ds_link test_ds_link_test->ds_link ad_return_url ad_return_url (public) ds_link->ad_return_url ds_collection_enabled_p ds_collection_enabled_p (public) ds_link->ds_collection_enabled_p ds_enabled_p ds_enabled_p (public) ds_link->ds_enabled_p ds_instance_id ds_instance_id (private) ds_link->ds_instance_id ds_permission_p ds_permission_p (private) ds_link->ds_permission_p

Testcases:
ds_link_test

ds_page_fragment_cache_enabled_p (public)

 ds_page_fragment_cache_enabled_p

Are we populating the page fragment cache?

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_page_fragment_cache_enabled_p ds_page_fragment_cache_enabled_p test_ds_features_enabled_test->ds_page_fragment_cache_enabled_p packages/acs-developer-support/lib/footer.tcl packages/acs-developer-support/ lib/footer.tcl packages/acs-developer-support/lib/footer.tcl->ds_page_fragment_cache_enabled_p packages/acs-developer-support/lib/toolbar.tcl packages/acs-developer-support/ lib/toolbar.tcl packages/acs-developer-support/lib/toolbar.tcl->ds_page_fragment_cache_enabled_p packages/acs-developer-support/www/request-info.tcl packages/acs-developer-support/ www/request-info.tcl packages/acs-developer-support/www/request-info.tcl->ds_page_fragment_cache_enabled_p template::adp_parse template::adp_parse (public) template::adp_parse->ds_page_fragment_cache_enabled_p

Testcases:
ds_features_enabled_test

ds_profile (public)

 ds_profile command [ tag ]

Helper proc for performance profiling of templates. This will record the total time spent within an invocation of a template (computed as time between the 'ds_profile start' and 'ds_profile stop' invocations inserted by the template engine).

Parameters:
command - Must be "start" or "stop".
tag (optional) - In practice, the path to the template being profiled.
  • start marks the beginning of a block.
  • stop marks the end of a block. Start and stops must match.

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_add_test ds_add_test (test acs-developer-support) ds_profile ds_profile test_ds_add_test->ds_profile ds_add ds_add (public) ds_profile->ds_add ds_enabled_p ds_enabled_p (public) ds_profile->ds_enabled_p

Testcases:
ds_add_test

ds_profiling_enabled_p (public)

 ds_profiling_enabled_p

Returns true if developer-support template profiling facilities are enabled.

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_profiling_enabled_p ds_profiling_enabled_p test_ds_features_enabled_test->ds_profiling_enabled_p ds_init ds_init (public) ds_init->ds_profiling_enabled_p packages/acs-developer-support/lib/toolbar.tcl packages/acs-developer-support/ lib/toolbar.tcl packages/acs-developer-support/lib/toolbar.tcl->ds_profiling_enabled_p packages/acs-developer-support/www/index.tcl packages/acs-developer-support/ www/index.tcl packages/acs-developer-support/www/index.tcl->ds_profiling_enabled_p

Testcases:
ds_features_enabled_test

ds_show_p (public)

 ds_show_p

Should we show developer-support on the current connection.

Partial Call Graph (max 5 caller/called nodes):
%3 test_ds_features_enabled_test ds_features_enabled_test (test acs-developer-support) ds_show_p ds_show_p test_ds_features_enabled_test->ds_show_p ds_enabled_p ds_enabled_p (public) ds_show_p->ds_enabled_p ds_permission_p ds_permission_p (private) ds_show_p->ds_permission_p ds_init ds_init (public) ds_init->ds_show_p packages/acs-bootstrap-installer/installer/www/blank-master.tcl packages/acs-bootstrap-installer/ installer/www/blank-master.tcl packages/acs-bootstrap-installer/installer/www/blank-master.tcl->ds_show_p packages/acs-developer-support/lib/footer.tcl packages/acs-developer-support/ lib/footer.tcl packages/acs-developer-support/lib/footer.tcl->ds_show_p packages/acs-developer-support/lib/toolbar.tcl packages/acs-developer-support/ lib/toolbar.tcl packages/acs-developer-support/lib/toolbar.tcl->ds_show_p

Testcases:
ds_features_enabled_test
[ show source ]