Skip to content
Lenarys Analytics Docs
Back to website
Intelligence Learning-time tracking

Learning-time tracking

Collect lightweight, privacy-relevant activity signals while a logged-in user is active on Moodle pages.

How it works

  1. Resolve the page

    Moodle maps the current page to a logical page type and instance.

  2. Count active time

    The browser counts only while the document is visible, the window is focused, and recent activity is within the idle timeout.

  3. Coordinate tabs

    A local-storage leader key prevents multiple open tabs from counting active time simultaneously.

  4. Send heartbeats

    The browser periodically sends bounded time and visit updates to Moodle.

  5. Aggregate

    The server updates total, daily, and hourly records in a transaction.

What is tracked

Logical page types include Lenarys Analytics reports, Moodle activities, courses, profiles, grades, reports, local plugins, and a site-level fallback. Each total record ties one user to one logical page and stores visits, seconds, first access, last access, and limited page parameters.

Tracking settings

SettingDefaultEffective limits
Enable learning-time trackingOffTracking emits no client configuration while disabled.
Heartbeat interval30 secondsClamped from 15 to 120 seconds.
Idle timeout90 secondsClamped from 30 to 600 seconds.
Accepted time per requestServer maximum of 120 seconds.

Storage

Plugin tables
local_la_time_page   # logical page identity
local_la_time_total  # user + page totals
local_la_time_day    # daily aggregates
local_la_time_hour   # hourly aggregates

Interpretation

Activity is not attainment. Tracking estimates active page presence. It cannot prove attention, comprehension, effort, or learning quality. Combine it with completion, grades, assessments, and human context.

Before enabling tracking, update the site privacy notice, define retention and access expectations, and confirm that the use is appropriate for the organization and jurisdiction.

Was this page helpful?

Your feedback is stored in this browser.