Index: openacs-4/packages/dotlrn/tcl/dotlrn-init.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/tcl/dotlrn-init.tcl,v diff -u -N -r1.44 -r1.45 --- openacs-4/packages/dotlrn/tcl/dotlrn-init.tcl 7 Apr 2018 08:59:39 -0000 1.44 +++ openacs-4/packages/dotlrn/tcl/dotlrn-init.tcl 18 Sep 2018 17:27:14 -0000 1.45 @@ -29,6 +29,36 @@ # if installed if {[dotlrn::is_instantiated]} { + # + # Create the caches. The sizes can be + # tailored in the config file like the following: + # + # ns_section ns/server/${server}/acs/dotlrn + # ns_param DotlrnCache 2000000 + # ns_param DotlrnCommunityCache 2000000 + # ns_param DotlrnUserCache 2000000 + # + # dotlrn-cache: general purpose cache + ::acs::Cache create ::dotlrn::dotlrn_cache \ + -package_key dotlrn \ + -parameter DotlrnCache \ + -default_size 2000000 + + # dotlrn-user_cache: user specific stuff + ::acs::KeyPartitionedCache create ::dotlrn::dotlrn_user_cache \ + -package_key dotlrn \ + -parameter DotlrnUserCache \ + -default_size 2000000 + + # dotlrn_community_cache: holds community specfic stuff like + # "package_id", "name", "portal_id" etc + ::acs::KeyPartitionedCache create ::dotlrn::dotlrn_community_cache \ + -package_key dotlrn \ + -parameter DotlrnCommunityCache \ + -default_size 2000000 + + + set package_id [dotlrn::get_package_id] # make sure we aren't inheriting permissions from dotlrn's parent object @@ -76,7 +106,7 @@ # init of each applet NOTE: this applet_add proc _must_ be able to be # called repeatedly since this script is eval'd at every server startup foreach applet [db_list select_not_installed_applets {}] { - if {[catch {dotlrn_applet::applet_call $applet AddApplet [list]} errMsg]} { + if {[catch {dotlrn_applet::applet_call $applet AddApplet [list]} errMsg]} { ns_log warning "dotlrn-init: AddApplet $applet failed\n$errMsg" } } @@ -106,7 +136,6 @@ ns_log notice "dotlrn-init: done" } - # Local variables: # mode: tcl # tcl-indent-level: 4