Module: Protocol::Redis::Methods::Server
- Defined in:
- lib/protocol/redis/methods/server.rb
Instance Method Summary collapse
-
#flushdb! ⇒ Object
Remove all keys from the current database.
-
#info ⇒ Object
Get information and statistics about the server.
Instance Method Details
#flushdb! ⇒ Object
Remove all keys from the current database.
48 49 50 |
# File 'lib/protocol/redis/methods/server.rb', line 48 def flushdb! call('FLUSHDB') end |
#info ⇒ Object
Get information and statistics about the server.
31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/protocol/redis/methods/server.rb', line 31 def info = {} call('INFO').each_line(Protocol::CRLF) do |line| key, value = line.split(':') if value [key.to_sym] = value.chomp! end end return end |