Sha256: 5f10672a7f4088155dc67d43534b643cdb69bda62f14854fa9bed88db8ca120f

Contents?: true

Size: 294 Bytes

Versions: 2

Compression:

Stored size: 294 Bytes

Contents

require 'redis'
require 'redis-sentinel'

redis = Redis.new(master_name: "example-test", sentinels: [{host: "localhost", port: 26379}, {host: "localhost", port: 26380}])
redis.set "foo", "bar"

while true
  begin
    puts redis.get "foo"
  rescue => e
    puts "failed?", e
  end
  sleep 1
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
redis-sentinel-1.1.1 example/test.rb
redis-sentinel-1.1.0 example/test.rb