Source: benlobaugh.medium.com

Highly Performant PHP Sessions with Redis

Category: PHP, api

To facilitate state in web apps, PHP provides a session handling mechanism.

Read more about PHP session handling at https://www.php.net/manual/en/book.session.php

That means if there are three ajax requests to the server, request two and three will be blocked waiting on the request in front of them.

To get it running all we need to do is update two lines in the php.ini file to instruct PHP to use Redis and where to find the Redis server. I will not cover how to set up a Redis server in this article.
Newsletter

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Fathom Analytics | Fast, simple and privacy-focused website analytics. Fathom Analytics | Fast, simple and privacy-focused website analytics.
Achieve superior email deliverability with ToastMail! Our AI-driven tool warms up inboxes, monitors reputation, and ensures emails reach their intended destination. Sign up today for a spam-free future. Achieve superior email deliverability with ToastMail! Our AI-driven tool warms up inboxes, monitors reputation, and ensures emails reach their intended destination. Sign up today for a spam-free future.
Community Partners