acs-authentication-procs.tcl

  • last updated 20 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
- fix test case

- add editor hints to keep spaces/tabs in the furture more consistent

  1. … 754 more files in changeset.

ad_proc reform:

- use nsf::proc for defining ad_procs, when nsf::proc is available

- nsf::proc is part of the environment of XOTcl2 and provides

an efficient, C-implemented argument parser that can replace

the scripted *__arg_parser of OpenACS.

- The benefits are performance and reduced memory consumption.

* Simple functions (where the calling overhead was a large

part of the execution times can become several times faster

(e.g. db_name is 3x faster, cookie handling is 2x faster),

for functions with much db-activities the percentage will

be less.

* The memory consumption (RSS) of a site like OpenACS.org

is reduced by about 15%.

NEW (with nsf::proc)

::ad_get_cookie x: 10.93 microseconds per iteration

::ad_get_cookie ad_session_id: 21.95 microseconds per iteration

::dt_systime: 24.89 microseconds per iteration

::db_name: 8.70 microseconds per iteration

::db_string dbqd.null.g "select version() from dual": 316.66 microseconds per iteration

::ad_convert_to_html "hello world": 102.29 microseconds per iteration

OLD (without nsf::proc)

::ad_get_cookie x: 19.42 microseconds per iteration

::ad_get_cookie ad_session_id: 30.10 microseconds per iteration

::dt_systime: 27.55 microseconds per iteration

::db_name: 32.28 microseconds per iteration

::db_string dbqd.null.g "select version() from dual": 366.69 microseconds per iteration

::ad_convert_to_html "hello world": 160.51 microseconds per iteration

======================================================================

proc mtime cmd {set c 5000

set t [time [list time $cmd $c]];

regexp {^(-?[0-9]+) +} $t _ mS1;

set ms [expr {$mS1*1.0/$c}];

return "[format %6.2f $ms] microseconds per iteration"

}

set tests {

{::ad_get_cookie x} {::ad_get_cookie ad_session_id} {::dt_systime}

{::db_name} {::db_string dbqd.null.g "select version() from dual"}

{::ad_convert_to_html "hello world"}

}

foreach t $tests {append ::_ $t ": " [mtime $t] \n}

set ::_

======================================================================

  1. … 9 more files in changeset.
Merging back to HEAD all changes that happened in branch oacs-5-8 between tags: vg-merge-oacs-5-8-from-20141027 and vg-merge-oacs-5-8-from-20150427

  1. … 520 more files in changeset.
Merging back to HEAD branch oacs-5-8 (using tag vg-merge-oacs-5-8-from-20141027).

  1. … 2547 more files in changeset.
- simplify code

  1. … 3 more files in changeset.
- brace expressions to allow for tcl compilation

- use "in" or not in (ni) operator instead of lsearch (for readability and performance)

  1. … 10 more files in changeset.
- use "in" or not in (ni) operator instead of lsearch (for readability and performance)

  1. … 2 more files in changeset.
- make exists_and_not_null explicit

  1. … 6 more files in changeset.
stub acs_mail_lite::send since ns_sendmail is not always the ultimate transport. (the second one)

stub acs_mail_lite::send since ns_sendmail is not always the ultimate transport.

make test case a bit more informative about failure mode

Running these test twice would lead to errors, due to test users not being

deleted. The tear-down stuff knows how to rollback the database, but caching

is a bit beyond its automated capability at the moment.

Normalizing string comparison operations into tcl 8.4 operations, enabling byte-code compilation for expressions and many conditionals

  1. … 367 more files in changeset.
Someone changed the local auth implementation to handle the "RetrievePassword"

operation (by e-mailing a note to the user which links to a reset password

page). This is cool. What's not cool is to change the behavior without

running tests on the package and correcting the one that looked for the

local auth implementation to return "not_supported" ...

Added categories to the automated test(s).

  1. … 3 more files in changeset.
Fixed password email change test case - turned out to be interaction between two test cases and the cache

Fixed parameters test case to expose problem with unique constraint/primary key on auth_driver_params on Oracle, and to do a better job of testing the parameters framework

Fixed header of file (said workflow)

auth_password_change proc: stubbing ns_sendmail and checking that email is sent to user on password change.

Tweaking test cases

changing test case to use auth::create_user instead of ad_user_new

Fixed problem with chaning password for a user causing the connection's authentication to change

  1. … 1 more file in changeset.
Show message when test fails

Fixed test cases

  1. … 1 more file in changeset.
- Code reviewed authority UI

- UseEmailForLoginP

- Refactored snapshot_p out of auth_authorities table and into auth_sync_retrieve service contract

- Email account owner on password change

  1. … 12 more files in changeset.
Made local accounts accept and store screen_name

  1. … 5 more files in changeset.
making proc authority::create set default values for not required columns. Also making proc use an update statement for 4 columns not taken by the plsql new function

  1. … 3 more files in changeset.
updating the authority API with the new columns

  1. … 3 more files in changeset.