glance/glance/api/v1
Arnaud Legendre 5148c9648f Decouple read chunk size from write chunk size
When using the copy_from option, readers and writers can have different
speeds to respectively read and write.
A reader timeout will happen if the writer is slow and the writer is
being asked to write a lot. This is currently happening when using
the VMware store and copying from an HTTP server. The reader is reading
16MB which takes too long to upload to vCenter which is causing a
timeout from the HTTP server. The writer should be able to control the
size of the chunks being read when using copy_from: this way the writer
will write fast enough to not make the reader timeout.

This patch addresses the issue by introducing the notion of read chunk
size and write chunk size. Each store can have its own value for read
and write. The write chunk size of the destination store will be used
as the read chunk size of the source store in case of an image-create
where the copy_from option is specified.

Closes-Bug: #1336168

Signed-off-by: Arnaud Legendre <alegendre@vmware.com>
Signed-off-by: Zhi Yan Liu <zhiyanl@cn.ibm.com>

Change-Id: I4e0c563b8f3a5ced8f65fcca83d341a97729a5d4
2014-07-23 14:31:25 -07:00
..
__init__.py Remove vim header 2014-01-14 16:03:28 +00:00
controller.py debug level logs should not be translated 2014-05-23 15:57:06 +02:00
filters.py Remove vim header 2014-01-14 16:03:28 +00:00
images.py Decouple read chunk size from write chunk size 2014-07-23 14:31:25 -07:00
members.py debug level logs should not be translated 2014-05-23 15:57:06 +02:00
router.py Do not allow HEAD images/detail 2014-04-04 18:37:31 -07:00
upload_utils.py Refactoring Glance logging lowering levels 2014-07-17 10:03:12 +00:00