'Call when there is no more data to send.
Overrides superclass implementation to send any footer metadata
after object data.
:param footer_metadata: dictionary of metadata items
to be sent as footers.'

def end_of_object_data(self, footer_metadata=None):

    if (self.state == DATA_SENT):
        raise ValueError('called    end_of_object_data    twice')
    elif ((self.state == NO_DATA_SENT) and self.mime_boundary):
        self._start_object_data()
    footer_body = json.dumps(footer_metadata)
    footer_md5 = md5(footer_body).hexdigest()
    tail_boundary = ('--%s' % (self.mime_boundary,))
    if (not self.multiphase):
        tail_boundary = (tail_boundary + '--')
    message_parts = [('\r\n--%s\r\n' % self.mime_boundary), 'X-Document:    object    metadata\r\n', ('Content-MD5:    %s\r\n' % footer_md5), '\r\n', footer_body, '\r\n', tail_boundary, '\r\n']
    self.queue.put(''.join(message_parts))
    self.queue.put('')
    self.state = DATA_SENT
