Add a reporter for verbs to track number of storage streams are needed

This commit is contained in:
Joseph Schorr 2018-03-23 14:39:38 -04:00
parent 110366f656
commit dd470bdc9d
7 changed files with 43 additions and 14 deletions

View file

@ -8,13 +8,13 @@ class TarImageFormatter(object):
"""
def build_stream(self, repo_image, tag, synthetic_image_id, get_image_iterator,
tar_stream_getter_iterator):
tar_stream_getter_iterator, reporter=None):
"""
Builds and streams a synthetic .tar.gz that represents the formatted tar created by this class's
implementation.
"""
return GzipWrap(self.stream_generator(repo_image, tag, synthetic_image_id, get_image_iterator,
tar_stream_getter_iterator))
tar_stream_getter_iterator, reporter=reporter))
def stream_generator(self, repo_image, tag, synthetic_image_id, get_image_iterator,
tar_stream_getter_iterator):