Redic::Sentinels

Gem Version Build Status Coverage Status Code Climate Dependency Status

Redic::Sentinels is a wrapper for the Redis client that fetches configuration details from sentinels.

Based on soveran/redisent

Installation

Add this line to your application's Gemfile:

gem 'redic-sentinels'

And then execute:

$ bundle

Or install it yourself as:

$ gem install redic-sentinels

Usage

hosts = [
  'localhost:26379',
  'localhost:26380',
  'localhost:26381'
]

redis = Redic::Sentinels.new hosts: hosts, 
                             master_name: 'mymaster', 
                             db: 1, # optional (default: 0)
                             password: 'pass' # optional

redis.call 'PING' # => 'PONG'

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/gabynaiman/redic-sentinels.

License

The gem is available as open source under the terms of the MIT License.