aistore.sdk.presence_poller
aistore.sdk.presence_poller
Module Contents
Classes
Data
API
Utility class for making a best-effort attempt at retrying HEAD calls to an object until it is present in cluster.
This class provides a way to delay this retry until the object is present.
Given an object size, create a retryer. Args: size (int) : Object size in bytes. Returns: tenacity.Retrying determining how to retry the given function.
Given a PreparedRequest, send a HEAD to that same object URL. Args: req (PreparedRequest): Initial request for an object.
Returns: Object attributes of the object in the initial request.
Calls HEAD on the object from the given PreparedRequest. Uses the object attributes to make an intelligent guess at when we should re-raise the error and proceed to the next retry, based on the size of the object. This method has no effect besides delaying a higher-level function until presence is confirmed or retries are exhausted.
Parameters:
Request made to AIS target before receiving initial error.