Skip to content

Commit

Permalink
MAGETWO-84106: [2.2.1] Implementation (fix) of session locking mechan…
Browse files Browse the repository at this point in the history
…ism in php-redis-session-abstract leads to 30 sec timeout
  • Loading branch information
dhorytskyi authored and Oleksandr Iegorov committed Nov 27, 2017
1 parent e83e22d commit aaa60b1
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions lib/internal/Magento/Framework/Session/SessionManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -504,18 +504,8 @@ public function regenerateId()
return $this;
}

//@see http://php.net/manual/en/function.session-regenerate-id.php#53480 workaround
if ($this->isSessionExists()) {
$oldSessionId = session_id();
session_regenerate_id();
$newSessionId = session_id();
session_id($oldSessionId);
session_destroy();

$oldSession = $_SESSION;
session_id($newSessionId);
session_start();
$_SESSION = $oldSession;
session_regenerate_id(true);
} else {
session_start();
}
Expand Down

0 comments on commit aaa60b1

Please sign in to comment.