Method: Moped::Connection#alive?

Defined in:
lib/moped/connection.rb

#alive?true, false

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Is the connection alive?

Examples:

Is the connection alive?

connection.alive?

Returns:

  • (true, false)

    If the connection is alive.

Since:

  • 1.0.0



18
19
20
# File 'lib/moped/connection.rb', line 18

def alive?
  connected? ? @sock.alive? : false
end