redis-reconnect

Redis client with autoreconnection for slow clients
0.3 Latest release released
kostya/redis-reconnect
8 2
Kostya M

redis-reconnect

Redis client with autoreconnection for slow clients (wrapper for stefanwille/crystal-redis). Used as part of redisoid shard.

Installation

Add this to your application's shard.yml:

dependencies:
  redis-reconnect:
    github: kostya/redis-reconnect

Usage

require "redis-reconnect"

r = Redis::Reconnect.new(host: "localhost", port: 6379)
r.set("bla", "a")
p r.get("bla")

Ok to use it with Pool (ysbaddaden/pool):

pool = ConnectionPool.new(capacity: 25) do
  Redis::Reconnect.new(host: "localhost", port: 6379)
end

pool.connection do |conn|
  conn.get "bla"
end
redis-reconnect:
  github: kostya/redis-reconnect
  version: ~> 0.3
License MIT
Crystal none

Authors

Dependencies 1

  • redis <= 1.11.0
    {'github' => 'stefanwille/crystal-redis', 'version' => '<= 1.11.0'}

Development Dependencies 0

Dependents 1

Last synced .
search fire star recently