Add rbd store support for zero size image

If glanceclient does not provide image size to RBD store add() it
will create a zero-size image and fail when writing to it. If
provided with zero size we now work out the size of each chunk
being written and resize the rbd image prior to each write. This
will be much slower than if new the image size on create but it
will at least work.

There is a corresponding glanceclient fix to ensure content-length
is set if known by the glanceclient, see bug 1220197

Change-Id: I014c4b71c77c92b9876786d1ba438cdb90f83233
Fixes: bug #1213880
Merge "Add rbd store support for zero size image"