class LBPost(Base): name = wsattr(wtypes.text, mandatory=True) nodes = wsattr(['LBNode'], mandatory=True) options = wsattr('LBOptions') protocol = wtypes.text algorithm = Enum(wtypes.text, 'ROUND_ROBIN', 'LEAST_CONNECTIONS') port = int virtualIps = wsattr(['LBVip'])
class LBLogsPost(Base): objectStoreType = Enum(wtypes.text, 'Swift') objectStoreEndpoint = wtypes.text objectStoreBasePath = wtypes.text authToken = wtypes.text
class LBPut(Base): name = wtypes.text algorithm = Enum(wtypes.text, 'ROUND_ROBIN', 'LEAST_CONNECTIONS')
class LBNodePut(Base): condition = Enum(wtypes.text, 'ENABLED', 'DISABLED') weight = int
class LBNode(Base): port = wsattr(int, mandatory=True) address = wsattr(wtypes.text, mandatory=True) condition = Enum(wtypes.text, 'ENABLED', 'DISABLED') backup = Enum(wtypes.text, 'TRUE', 'FALSE') weight = int
class LBMonitorPut(Base): type = Enum(wtypes.text, 'CONNECT', 'HTTP') delay = int timeout = int attemptsBeforeDeactivation = int path = wtypes.text
class DevicePut(Base): status = Enum(wtypes.text, 'ONLINE', 'ERROR') statusDescription = wsattr(wtypes.text, mandatory=True)
class LBPut(Base): name = wtypes.text algorithm = Enum(wtypes.text, 'ROUND_ROBIN', 'LEAST_CONNECTIONS') options = wsattr('LBOptions')
:param query: A list of queries. :param storage_func: The name of the storage function to very against. """ translation = {'customer': 'customer_id'} criterion = {} for q in query: key = translation.get(q.field, q.field) criterion[key] = q.as_dict() criterion.update(kw) return criterion operation_kind = Enum(str, 'lt', 'le', 'eq', 'ne', 'ge', 'gt') class Query(Base): """ Query filter. """ _op = None # provide a default def get_op(self): return self._op or 'eq' def set_op(self, value): self._op = value