Upload
others
View
0
Download
0
Embed Size (px)
Citation preview
Heartbeat Monitoring for Quiz ModuleBy Moodle Project Team @ IIT Bombay
1 | User starts quiz
4 | Quiz time extended
2 | Time lost due to network/hardware problem
3 | Create user-override
Current Scenario
The Challenge
Scenario
During a quiz attempt, user encounters a problem which hampers the quiz progress.
Problem
➔ No way to automatically quantify the lost time
➔ Need to compensate for the lost time manually with the help of user overrides
Proposed Solution
01
02
03
04
Monitor the health of the connection
using heartbeats provided by websockets
Record the connections and
disconnections of a user attempting a
quiz
Automatically set user-overrides to extend the quiz time limit by the amount of time lost
Calculate the time lost between connections
Proposed technology & methodology to be used
➔ NodeJS, Express, Socket.IO for heartbeat tracking
➔ Trigger moodle to set user-overrides automatically
Node.js
● JavaScript runtime built on Chrome's V8 JavaScript engine
● Uses an event-driven, non-blocking I/O model that makes it lightweight and efficient
Socket.IO
Socket.IO is composed of two parts● A server that integrates with (or mounts on) the
Node.JS HTTP Server | socket.io● A client library that loads on the browser side
| socket.io-client
Express
● A minimal and flexible Node.js web application framework
● Provides a thin layer of fundamental web application features, without obscuring Node.js features
Implementation
What is heartbeat mechanism?
Integration into Moodle
Plugin type Quiz access rules
Component name (Frankenstyle)
quizaccess_heartbeatmonitor
Moodle path /mod/quiz/accessrule/heartbeatmonitor
DescriptionHeartbeat monitoring module for Moodle Quiz for auto-incrementing quiz timelimit.
Moodle versions 3.3 and above
Source control URL https://github.com/IITBombayWeb/moodle-quizaccess_heartbeatmonitor
Discussion https://moodle.org/mod/forum/discuss.php?d=360672
Work Flow
Step 1 | Monitor the health of the connection using heartbeats provided by websockets
● Node.js used as a Web Server● Socket.IO used with Express for providing a
bi-directional communication channel between a client and a server
Step 2 | Record the connections and disconnections of a user attempting a quiz
Step 3 | Calculate the time lost between connections
A log is maintained by recording user life status, whether the user is live(/online) or dead(/offline).
Step 4 | Automatically set user-overrides to extend the quiz time limit by the amount of time lost
x1 | User starts quiz
3 | Quiz time extended automatically
2 | Time lost due to network problem
No manual intervention
Moodle Quiz in future
ConclusionBy applying concept of heartbeats in moodle quiz, we will be automating the process of detection of users who encounter problems like network failure, etc. and generation of user overrides for extending their quiz time limit.
Current project status | In development