Module: Redisbetween

Defined in:
lib/redisbetween.rb,
lib/redisbetween/version.rb

Defined Under Namespace

Modules: ClientPatch Classes: Error

Constant Summary collapse

PIPELINE_START_SIGNAL =
'🔜'
PIPELINE_END_SIGNAL =
'🔚'
VERSION =
"0.2.2"

Class Method Summary collapse

Class Method Details

.default_socket_path(host, port, path = nil) ⇒ Object



105
106
107
# File 'lib/redisbetween.rb', line 105

def self.default_socket_path(host, port, path = nil)
  ['/var/tmp/redisbetween', host, port, path].compact.join('-') + '.sock'
end

.socket_path(option, host, port, path = nil) ⇒ Object



97
98
99
100
101
102
103
# File 'lib/redisbetween.rb', line 97

def self.socket_path(option, host, port, path = nil)
  if option.respond_to?(:call)
    option.call(host, port, path)
  else
    default_socket_path(host, port, path)
  end
end