It sounds like Redis is being cleared in some way.
Do you have an external Redis server or is it running on the same server?
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
We are using Laravel 5.8 on an e-commerce website. Some of our customers inform us that they can add any item to their basket. When we look at the log files, we see that those customers' basket is duplicated every time. We release that session is destroyed when page is refreshed.
Interestingly, we do not get this error on the local environment. Also, this issue does not happen every time. I only come across this issue a couple of times in chrome browser. Lastly, the problem only can be solved only if I clear site data on the chrome development console.
Session.php:
'driver' => 'redis',
'lifetime' => 60*24*30,
'expire_on_close' => false,
'encrypt' => false,
'files' => storage_path('framework/sessions'),
'connection' => 'session',
'table' => 'sessions',
'store' => null,
'lottery' => [2, 100],
'cookie' => 'my_session',
'path' => '/',
'domain' => env('SESSION_DOMAIN', null),
'secure' => env('SESSION_SECURE_COOKIE', false),
'http_only' => true,
Thanks for advance.
Please or to participate in this conversation.