-
Notifications
You must be signed in to change notification settings - Fork 16
Online Sessions guess
Sessions are somehow "guessed" using the Moodle Log entries.
Moodle Log record only User's actions (clicks on links or buttons), not the time spent by the User viewing a content (a page, a pdf, a video...). So there is no way to know how long the User actually spend viewing a long content without any other action.
For example, we have a 20 minutes video in a Course. Moodle records the action of the User opening the video and no other action for the following 20 minutes.
We have no way to know if the User had actually viewed the video or if he shut the browser off and returned after 20 minutes.
The idea is to have a reasonable guess of the time spent online, for never underestimating the actual time, considering acceptable a slight overestimate.
So the Register uses this rules to guess Online Sessions:
- When less time than Session Timeout (see below) elapses between two consecutive Log entries of the same User, the User is considered to be continuously working online.
- When longer than Session Timeout elapse (there could be days between two visits) the User is considered to have logged out ONE HALF the Session Timeout after the first Log entry, and than logged in again at the second.
Also, that a Register take account only of the Log entries related to the Tracked Courses (see below), not all the Log entries of the User.
Any Logout event in the Moodle's Log is ignored.
User may leave the site with an explicit logout, just leaving the site or closing the browser. If Logout event would be considered, Online Sessions of users doing explicit logout would be statistically underestimated compared to users not doing logout.
Session Timeout may be configured in each Attendance Register module instance.
Default is 30 mins. This is an average value usually good for most of cases, but it overestimates a little the length of the Session.
If set to a value too short, long sessions of work (eg. viewing a long video, reading a long document) will break down in many shorter sessions.
On the opposite, if the value is too long, the module will highly overestimate the sessions (with a timeout of 1 hour, if the user peek at a course for 5 minutes, a session of about 35 will be recorded)
Please note that Session Timeout parameter used by the Register has nothing to do with the Moodle's HTTP session length.
The idea of Sessions estimate based on Moodle's logs, based on a Session Timeout, is taken from the Register Module for Moodle 1.x, originally created by Domenico Pontari (fairsayan@gmail.com).