class documentation

class AbstractStubClient(AbstractClient):

Known subclasses: ganeti.metad.Client, ganeti.wconfd.Client

View In Hierarchy

An abstract Client that connects a generated stub client to a Transport.

Subclasses should inherit from this class (first) as well and a designated stub (second).

Method __init__ Constructor for the class.
Method _GenericInvoke Undocumented
Method _GetAddress Returns the socket address

Inherited from AbstractClient:

Method CallMethod Send a generic request and return the response.
Method Close Close the underlying connection.
Method close Same as Close, to be used with contextlib.closing(...).
Instance Variable allow_non_master Undocumented
Instance Variable timeouts Undocumented
Instance Variable transport Undocumented
Instance Variable transport_class Undocumented
Instance Variable version Undocumented
Method _CloseTransport Close the transport, ignoring errors.
Method _InitTransport (Re)initialize the transport if needed.
Method _SendMethodCall Undocumented
def __init__(self, timeouts=None, transport=t.Transport, allow_non_master=None):

Constructor for the class.

Arguments are the same as for AbstractClient. Checks that SOCKET_PATH attribute is defined (in the stub class).

Parameters
timeouts:list of intstimeouts to be used on connect and read/write
transport:Transport or another compatible classthe underlying transport to use for the RPC calls
allow_non_master:boolskip checks for the master node on errors
def _GenericInvoke(self, method, *args):

Undocumented

def _GetAddress(self):

Returns the socket address