AAP-54345: library.storage: implement Directory, S3, Segment, CRC, CRCMutual #246
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.


Issue: AAP-54345
Pulled library, docs & worker example changes from #243 (without cli updates to use it),
pulled segment from #234 and adjusted to match,
pulled crc implementations from #216.
This implements
metrics_utility.library.storage:read-write:
StorageDirectoryStorageS3write-only:
StorageCRCStorageCRCMutualStorageSegmentSupported methods:
storage.put(name, ...)- should upload to storage, and raise on failurestorage.put(name, dict=data)- uploads a dict, likely as json data, or a .json filestorage.put(name, filename=path)- uploads a local file (by name)storage.put(name, fileobj=handle)- uploads an opened local file or a compatible object (by a file-like handle)storage.get(name)- (context manager) should download from storage into a temporary file, yield the temporary filename, and remove the file again.Also supported -
exists(name) -> Bool,remove(name),glob(pattern) -> [filenames].(CRC, CRCMutual & Segment only support
put.)