Class: Cassandra::SafeClient
- Inherits:
-
Object
- Object
- Cassandra::SafeClient
- Defined in:
- lib/cassandra_client/safe_client.rb
Instance Method Summary collapse
-
#initialize(client, transport) ⇒ SafeClient
constructor
A new instance of SafeClient.
- #method_missing(*args) ⇒ Object
Constructor Details
#initialize(client, transport) ⇒ SafeClient
Returns a new instance of SafeClient.
4 5 6 7 |
# File 'lib/cassandra_client/safe_client.rb', line 4 def initialize(client, transport) @client = client @transport = transport end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(*args) ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'lib/cassandra_client/safe_client.rb', line 9 def method_missing(*args) @client.send(*args) rescue IOError @transport.open raise if defined?(once) once = true retry end |