b.s.r.SmartServerRepositoryRequest(SmartServerRequest) : class documentation

Part of bzrlib.smart.repository View In Hierarchy

Known subclasses: bzrlib.smart.packrepository.SmartServerPackRepositoryAutopack, bzrlib.smart.repository.SmartServerRepositoryGatherStats, bzrlib.smart.repository.SmartServerRepositoryGetParentMap, bzrlib.smart.repository.SmartServerRepositoryGetStream, bzrlib.smart.repository.SmartServerRepositoryInsertStreamLocked, bzrlib.smart.repository.SmartServerRepositoryIsShared, bzrlib.smart.repository.SmartServerRepositoryLockWrite, bzrlib.smart.repository.SmartServerRepositoryReadLocked, bzrlib.smart.repository.SmartServerRepositorySetMakeWorkingTrees, bzrlib.smart.repository.SmartServerRepositoryTarball, bzrlib.smart.repository.SmartServerRepositoryUnlock, bzrlib.smart.repository.SmartServerRequestHasRevision

Common base class for Repository requests.
Method do Execute a repository request.
Method do_repository_request Override to provide an implementation for a verb.
Method recreate_search Recreate a search from its serialised form.
Method recreate_search_from_recipe Recreate a specific revision search (vs a from-tip search).

Inherited from SmartServerRequest:

Method __init__ Constructor.
Method execute Public entry point to execute this request.
Method do_body Called if the client sends a body with the request.
Method do_chunk Called with each body chunk if the request has a streamed body.
Method do_end Called when the end of the request has been received.
Method setup_jail Undocumented
Method teardown_jail Undocumented
Method translate_client_path Translate a path received from a network client into a local
Method transport_from_client_path Get a backing transport corresponding to the location referred to by
Method _check_enabled Raises DisabledMethod if this method is disabled.
def do(self, path, *args):
Execute a repository request.

All Repository requests take a path to the repository as their first argument. The repository must be at the exact path given by the client - no searching is done.

The actual logic is delegated to self.do_repository_request.

Parametersclient_pathThe path for the repository as received from the client.
ReturnsA SmartServerResponse from self.do_repository_request().
def do_repository_request(self, repository, *args):
Override to provide an implementation for a verb.
def recreate_search(self, repository, search_bytes, discard_excess=False):
Recreate a search from its serialised form.
Parametersdiscard_excessIf True, and the search refers to data we don't have, just silently accept that fact - the verb calling recreate_search trusts that clients will look for missing things they expected and get it from elsewhere.
def recreate_search_from_recipe(self, repository, lines, discard_excess=False):
Recreate a specific revision search (vs a from-tip search).
Parametersdiscard_excessIf True, and the search refers to data we don't have, just silently accept that fact - the verb calling recreate_search trusts that clients will look for missing things they expected and get it from elsewhere.
API Documentation for Bazaar, generated by pydoctor at 2022-06-16 00:25:16.