get_director_response

requests_pelican.director.get_director_response(path, federation=None, *, cache=True, timeout=60, **kwargs)[source]

Query for director information for a Pelican path.

Parameters

pathstr

The Pelican data path, must be a sub-path of the right namespace for this DirectorResponse.

federationstr

The name or URL of the Pelican Federation that contains the path. This is required if path isn’t a valid Pelican URI from which the federation URL can be parsed.

cachebool, str

Whether to use a cached copy of the DirectorResponse for the federation (True or False). If cache="update" is given, query the director again and update the cache with the new response.

timeoutint, optional

The timeout (seconds) after which to abort requests to the Pelican director.

randombool

If True, shuffle the list of URLs before returning.

kwargs

Other keyword arguments are passed to get_director_response.

Returns

dirrespDirectorResponse

The response from the Pelican director.