?
avatar stAn47
stAn47
24 Aug 2018

Steps to reproduce the issue

Joomla 3.8.11 + siteground VPS

Dear friends, we are having huge problems with Joomla Database sessions when there are more concurent ajax calls to the site via http/2 (over https).

we could not find a proper solution how to lock session row in #__session table so that other concurrent calls wait until the row lock is released.

for this reason we would suggest to implement a support for calls which do not store sessions so there are no inconsitances upon such calls.

example of usage:

  • get additional product data for google tracking on a product details page upon add-to-cart which can eventually load 3 ajax calls (one to get tracking data, another to update the cart, another to update dynamic modules such as the cart)

the ideal solution would be for com_ajax:
if
&nosessionwrite=1

is used in URL query, there would be no write to the session via session handlers especially database (which doesn't seem to provide proper locking in our case)

example implementation:
\libraries\joomla\session\storage\database.php

public function write($id, $data)
	{
$nosessionwrite = JFactory::getApplication()->input->get('nosessionwrite', 0); 
if (!empty($nosessionwrite)) return true; 

another possible solution is to make sure we are updating our own session:

another more generic solution would probably be to add a support for application global variable such as

$nosessionwrite = JFactory::getApplication()->get('nosessionwrite', false);

if (!empty($nosessionwrite)) {
//prevent session write in any handler
}

the above code would also allow us to control GDPR session data, so they are not stored when the application logic decides not to store guest sessions.

any ideas are welcome,

best regards, stAn

avatar stAn47 stAn47 - open - 24 Aug 2018
avatar joomla-cms-bot joomla-cms-bot - labeled - 24 Aug 2018
avatar franz-wohlkoenig franz-wohlkoenig - change - 24 Aug 2018
Category JavaScript
avatar franz-wohlkoenig franz-wohlkoenig - change - 31 Aug 2018
Status New Information Required
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 31 Aug 2018

can a more experienced User please answer on this Feature Request as it has since one Week Status "New"?


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/21835.

avatar mbabker
mbabker - comment - 31 Aug 2018

Joomla requires a session to work and a request variable to skip writing this data is a bad idea and one we shouldn't support.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 31 Aug 2018

thanks @mbabker for Comment; so closing Issue.

avatar franz-wohlkoenig franz-wohlkoenig - change - 31 Aug 2018
Status Information Required Closed
Closed_Date 0000-00-00 00:00:00 2018-08-31 11:59:36
Closed_By franz-wohlkoenig
avatar joomla-cms-bot joomla-cms-bot - change - 31 Aug 2018
Closed_Date 2018-08-31 11:59:36 2018-08-31 11:59:37
Closed_By franz-wohlkoenig joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 31 Aug 2018
avatar joomla-cms-bot
joomla-cms-bot - comment - 31 Aug 2018

Add a Comment

Login with GitHub to post a comment