l.s.l.swift : module documentation

Part of lp.services.librarianserver

Move files from Librarian disk storage into Swift.
Function quiet_swiftclient Undocumented
Function to_swift Copy a range of Librarian files from disk into Swift.
Function rename Undocumented
Function swift_location Return the (container, obj_name) used to store a file.
Function filesystem_path Undocumented
Class SwiftStream Undocumented
Class HashStream Read a file while calculating a checksum as we go.
Class ConnectionPool No class docstring; 2/5 methods documented
Function connection Undocumented
Function _put Undocumented
def quiet_swiftclient(func, *args, **kwargs):
Undocumented
def to_swift(log, start_lfc_id=None, end_lfc_id=None, remove_func=False):
Copy a range of Librarian files from disk into Swift.

start and end identify the range of LibraryFileContent.id to migrate (inclusive).

If remove_func is set, it is called for every file after being copied into Swift.

def rename(path):
Undocumented
def _put(log, swift_connection, lfc_id, container, obj_name, fs_path):
Undocumented
def swift_location(lfc_id):
Return the (container, obj_name) used to store a file.

Per https://answers.launchpad.net/swift/+question/181977, we can't simply stuff everything into one container.

def filesystem_path(lfc_id):
Undocumented
@contextmanager
def connection():
Undocumented
API Documentation for Launchpad, generated by pydoctor at 2018-02-22 00:00:13.