Class: Protobuf::Rpc::Connectors::Socket

Inherits:
Base
  • Object
show all
Includes:
Logging, Common
Defined in:
lib/protobuf/rpc/connectors/socket.rb

Instance Attribute Summary

Attributes included from Common

#error

Attributes inherited from Base

#complete_cb, #failure_cb, #options, #success_cb

Instance Method Summary collapse

Methods included from Logging

initialize_logger, #log_exception, #logger, #sign_message

Methods included from Common

#any_callbacks?, #complete, #data_callback, #failure, #initialize_stats, #parse_response, #post_init, #request_bytes, #request_caller, #setup_connection, #succeed, #timeout, #timeout_wrap, #validate_request_type!, #verify_callbacks, #verify_options!

Methods inherited from Base

#first_alive_load_balance?, #initialize, #ping_port, #ping_port_enabled?

Constructor Details

This class inherits a constructor from Protobuf::Rpc::Connectors::Base

Instance Method Details

#log_signatureObject



19
20
21
# File 'lib/protobuf/rpc/connectors/socket.rb', line 19

def log_signature
  @_log_signature ||= "[client-#{self.class}]"
end

#send_requestObject



10
11
12
13
14
15
16
17
# File 'lib/protobuf/rpc/connectors/socket.rb', line 10

def send_request
  timeout_wrap do
    setup_connection
    connect_to_rpc_server
    post_init
    read_response
  end
end