• last updated 10 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Don't complain when flushing per-thread cache without content

Added per-request-cache for parameter::get similar to parameter handling in xotcl-core

This change improves scalability especially on sites with high numbers

of concurrent requests by reducing the number of required locks in

general. This change keeps the parameter dict in a per-request cache

to reduce potentially high number of nsv locks, when parameters of a

package are queried a often per request. Without this change we see on

some sites > 100 locks on the ad_param-nsv per request. Alone the

request-procesor queries a larger set of parameters from the acs-core

package, which requires now a single lock operation.

Using the per-request cache has the advantave of avoiding locks and

keeping the internal representations of tcl-objs (whereas ns_cache or

nsvs use plain strings).

extend/debug simplified where/unless query language

    • -17
    • +36
    /openacs-4/packages/xowiki/tcl/xowiki-procs.tcl
modernize idiom

use fully qualified cmd name in directdispatch

    • -2
    • +2
    /openacs-4/packages/xowiki/tcl/xowiki-procs.tcl
Added support for tailored messages when autosave is rejected

Optionally, the AJAX call from autosave can be answered with

a JSON structure containing a "feedback". If this is provided, this

is presented to the user. The mechanism can be extended in the

future to include some reason code, etc. for further automatic

processing in JavaScript.

With this change, the inclass-exam-answer workflow will use this

to comminicate the reasone for rejected autosave operations in

situations, where the examtime is up.

keep track of position of a question in the form for correct scrambling also for filtering by form object

background: randomization depends on the per-user random values and by the position

of a test-item in an exam. If one is filtering just for the test-item,

the position of this item in the exam was lost. Now, we keep track

in the filtering cases

minor update of call pattern and debug line

mitigate attacks, where the referer header field is changed to a malicious value

The problem does not exist, when CSP is defined properly.

Many thanks to Frank Bergmann for sharing the pen-test protocol

make sure, the end_clock is always an integer (as required by "clock format")

improve input checking

    • -7
    • +16
    /openacs-4/packages/xowiki/tcl/package-procs.tcl
prefer xowf message catalog

Performance improvement: make "apm_version_names_compare" faster by a factor of ~100

The function "apm_version_names_compare" is called relatively often

and issues an SQL query. The function is stable (returns always the

same results for the same input) and called with only a few different

input values. By using acs::per_thread_cache the performance improves

from 265 microseconds to 2 microseconds; by using the per-tread cache

the operation scales better since it is fully lock-free (once cached).

Deactivate compatibility with versions before OpenACS 5.2 (2005) in

busy code, but leave it there commented out for easy reactivating in

legacy applications.

use variable to reference kernel id, white space and comment changes

provide means for omit the audio alarm control in the countdown timer

Remove backward compatibility check in busy code for versions before 5.1.3 (2004)

The checks for backwards compatibility have on busy sites the highest

hit rates of all entries in the util-memoize cache. Since we require the latest

OpenACS 5.9.* for upgrade to 5.10, this can be removed (17 years later).

https://openacs.org/bugtracker/openacs/bug?format=table&f%5fstate=8&bug%5fnumber=2200

Show form-field statistics in exam-summary for autograded exams:

- Provide statitics for autograded exams and show this (currently for

MC/SC) in the exam summary. The statistics are generated when the

exam-protocol is rendered and persisted statistics in the workflow

instance.

- Added switch "-generic" to answer_form_field_objs to obtain the

question with all alternatives (not constraint to "show_max") and

without shuffling. This is needed in cases, where e.g. statistics

should be provided for all alternatives shown to all students.

- Question_manager->question_info: separate computation from HTML rendering

- Added statistics handler for the WorkflowPage class to collect

details from the form-fields.

- new private function "tdom_render" (might be useful, but is the

committed version not used)

- split out "spec_to_dict" from "fc_to_dict", since it us also useful on its own

to work on single form-constraint specs.

- make methods add_to_fc and replace_in_fc available to the full AssessmentInterface

    • -65
    • +220
    /openacs-4/packages/xowf/tcl/test-item-procs.tcl
    • -0
    • +26
    /openacs-4/packages/xowf/tcl/xowf-procs.tcl
Refactor form-field statistics (part 1)

- Start move of statistics from being collected in form-fields to

collecting these in the workflow objects. The original code was

developed with less randomization (e.g. no x out of y alternatives)

which requires that the formfields have to be reset multiple times

(e.g. for multiple students in the exam protocol). The exam-protocol

handler cleans regularly the form-fields, which caused also the

deletion of statistics. Collecting these in the (exam) workflow is

safe.

- Collect correct and incorrect statistics per alternative. Since

different students might see different alternatives calculating the

successrate can only be performed by the students having seens this

alternative.

    • -2
    • +2
    /openacs-4/packages/xowiki/xowiki.info
    • -1
    • +17
    /openacs-4/packages/xowiki/tcl/xowiki-procs.tcl
fix typo

remove indent as well on xotcl procs, handle also per-object methods the same way

added support for "ns_trim -prefix".

The command is predefined in NaviServer; if not available, a comatibility version is added.

This change also mitigates a potential memory-leak problem in nsv_dict with certain

versions of NaviServer which might lead on busy sites to problems.

    • -2
    • +2
    /openacs-4/packages/acs-tcl/acs-tcl.info
fix typo

    • -1
    • +1
    /openacs-4/packages/xowf/lib/inclass-quiz.wf
add publish status to default list of columns in child-resources

    • -1
    • +4
    /openacs-4/packages/xowiki/tcl/folder-procs.tcl
Fix typo

complete query variables

prettify API browser rendering for nx methods

- remove redundant doc block

- remove indentation

make sure, no commented out code is added to the proc doc

    • -13
    • +19
    /openacs-4/packages/xooauth/tcl/ms-procs.tcl
beautify labels of ensemble methods in object browser

added support for NX ensemble methods