Sessions table is no longer defined in system_schema

Created on 17 May 2024, 12 months ago
Updated 20 May 2024, 12 months ago

As indicated by the recent change record ( https://www.drupal.org/node/3431286 ), Drupal no longer defines the sessions table in `system_schema()`. This represents a significant alteration in how sessions are handled, which potentially impacts how modules interact with session data.
The Autologout module has functionality that directly queries the sessions table to determine user activity and manage automatic logouts. With the removal of the sessions table definition from `system_schema()`, this direct approach may no longer be reliable or functional in the same manner with future versions of Drupal.

Problem/Motivation

Since the sessions table is no longer defined via `system_schema()`, direct database queries to the sessions table within the Autologout module lead to sessions table not found.

Proposed resolution

We need to identify the new best practices and methods recommended by Drupal core for accessing session data and update the Autologout module accordingly. The module's functionality should be refactored to use the appropriate alternative API if available or implement a new method to work with sessions in a manner that is compatible with the latest Drupal core changes.

Proposed Solution:

A thorough review of the Autologout module's codebase is needed to identify all instances where it directly queries the sessions table. Each instance should be updated to use the current Drupal API for session handling, following the lead of core modules and adhering to the guidance provided in the change record.

User interface changes

None anticipated at this time.

API changes

Direct queries to the sessions table will be replaced with the updated API functions/methods provided by Drupal core for session handling.

Data model changes

None anticipated as this should be a direct adaptation to the API changes in core without affecting the stored data model.

This issue requires attention to ensure that the Autologout module remains functional and in sync with the core Drupal standards as they evolve.

📌 Task
Status

Active

Version

1.0

Component

Code

Created by

🇮🇳India rajeshreeputra Pune

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024