'Prepare headers for uploading an object
:param object_name: The full name of the object being updated
:type object_name: ``str``
:param object_size: The size of the object. In case of PageBlobs,
this indicates the maximum size the blob can grow to
:type object_size: ``int``
:param extra: Extra control data for the upload
:type extra: ``dict``
:param meta_data: Metadata key value pairs
:type meta_data: ``dict``
:param blob_type: Page or Block blob type
:type blob_type: ``str``'

def _prepare_upload_headers(self, object_name, object_size, extra, meta_data, blob_type):

    headers = {}
    if (blob_type is None):
        blob_type = self.ex_blob_type
    headers['x-ms-blob-type'] = blob_type
    self._update_metadata(headers, meta_data)
    if (object_size is not None):
        headers['Content-Length'] = object_size
    if (blob_type == 'PageBlob'):
        headers['Content-Length'] = 0
        headers['x-ms-blob-content-length'] = object_size
    return headers
