Download the PHP package flownative/redis-sentinel without Composer

On this page you can find all versions of the php package flownative/redis-sentinel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package redis-sentinel

MIT license Packagist Maintenance level: Love

Flow Redis Cache Backend with Sentinel Support

This package provides a Redis cache backend with Sentinel support.

Installation

The package is installed as a regular Flow package via Composer. For your existing project, simply include flownative/redis-sentinel into the dependencies of your Flow or Neos distribution:

Usage

The RedisBackend contained in this package can be used as a drop-in-replacement for the Redis backend provided by the neos/cache package.

For regular use with a standalone Redis server, provide configuration in your Caches.yaml like so:

Of course you can also set concrete values instead of using environment variables.

Note that you can set two different timeouts:

You can specify float numbers as timeout values. For example, use 0.5 for setting the timeout to half a second.

When Redis is running in a high availability setup with Sentinel servers, you need to configure the Redis Backend to access the Sentinel servers instead of the actual Redis nodes.

Depending on your setup, this may look like the following:

Note that "service" is the name of your Redis cluster (which is "mymaster" in most default configurations).

This package will use the same password for all connections, there is currently no support for specifying different passwords for Sentinel and client servers.

Logging

This cache backend will log errors, such as connection timeouts or other problems while communicating with the Redis servers.

If a connection error occurs during a request, it is likely, that more errors of the same type will happen. Therefore, those messages will, by default, be de-duplicated: If the messages of an error is identical with one which already has been logged during the current CLI / web request, it will not be logged another time.

You can disable de-duplication logged errors for debugging purposes by setting the respective backend option to false:

If you don't want errors being logged – for example, because you log errors via the MultiBackend – you can turn off logging for this cache backend:

Command Line Tool

This package provides CLI commands which can help debugging configuration or connectivity issues.

redissentinel:list

Displays configuration of Redis Sentinel cache backends, including those backends which are defined as a sub-backend of a Multi Backend.

redissentinel:connect

Tries to connect with the specified cache. If the cache is using a Multi Backend, this command will skip the Multi Backend behavior and instantiate the Redis Sentinel Backend directly. Errors are display and explained, if possible.

Tests

You can adjust the host, port and password used in the functional tests using the environment variables REDIS_HOST, REDIS_PORT and REDIS_PASSWORD.

Credits

This cache backend was developed by Robert Lemke of Flownative, based on the Neos Flow Redis Backend, originally created by Christopher Hlubek and later improved by the Neos core team.


All versions of redis-sentinel with dependencies

PHP Build Version
Package Version
Requires neos/flow Version ^7.0 || ^8.0 || ^9.0
neos/cache Version ^7.0 || ^8.0 || ^9.0
ext-zlib Version *
predis/predis Version ^2.0
php Version 8.1.* || 8.2.* || 8.3.*
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package flownative/redis-sentinel contains the following files

Loading the files please wait ....