TaskCollect
Toggle Dark/Light/Auto modeToggle Dark/Light/Auto modeToggle Dark/Light/Auto modeBack to homepage

Database

TaskCollect uses Redis 7 as its primary user credentials database. TaskCollect will not accept any other version of Redis.

Redis’ default of port 6379 and database 0 is used, although this can be changed via the config.json file.

If TaskCollect is being run in production, you must ensure that the Redis server is not exposed to any outside networks.

User credentials are stored using Redis hashes, using the following key reference:

school:<school>:studentID:<ID>

where <school> is the school name and <ID> is the unique student ID that the school provides. This allows TaskCollect to support multiple schools if needed.

Currently, the following information on students are stored:

  • token: TaskCollect session token
  • school: student’s school codename
  • username: student’s username
  • password: student’s password
  • daymap: DayMap session token
  • gclass: Google Classroom authentication token

Furthermore, TaskCollect also creates an index of current session tokens, using the following key reference, where <token> is the current session token. TaskCollect’s session tokens last for 3 days and by extension, this data is only stored for 3 days as well.

studentToken:<token>

studentToken:<token> also stores a Redis hash and contains the following information:

  • studentID: student’s username
  • school: student’s school name

By using this token-based index rather than school:<school>:studentID:<ID>, it allows for faster look-ups using the TaskCollect token as a reference, rather than the alternative of looping through each student ID in an attempt to fetch the session token.

A list of students per school is also stored via school:<school>:studentList, which is a Redis set containing the unique student IDs for each school. Currently, it is not used for anything, although it may be useful in the future.