'Handle HTTP POST request.'

@public
@timing_stats()
def POST(self, req):

    (drive, part, account, container) = split_and_validate_path(req, 4)
    req_timestamp = valid_timestamp(req)
    if ('x-container-sync-to' in req.headers):
        (err, sync_to, realm, realm_key) = validate_sync_to(req.headers['x-container-sync-to'], self.allowed_sync_hosts, self.realms_conf)
        if err:
            return HTTPBadRequest(err)
    if (self.mount_check and (not check_mount(self.root, drive))):
        return HTTPInsufficientStorage(drive=drive, request=req)
    broker = self._get_container_broker(drive, part, account, container)
    if broker.is_deleted():
        return HTTPNotFound(request=req)
    broker.update_put_timestamp(req_timestamp.internal)
    metadata = {}
    metadata.update(((key, (value, req_timestamp.internal)) for (key, value) in req.headers.items() if ((key.lower() in self.save_headers) or is_sys_or_user_meta('container', key))))
    if metadata:
        if ('X-Container-Sync-To' in metadata):
            if (('X-Container-Sync-To' not in broker.metadata) or (metadata['X-Container-Sync-To'][0] != broker.metadata['X-Container-Sync-To'][0])):
                broker.set_x_container_sync_points((-1), (-1))
        broker.update_metadata(metadata, validate_metadata=True)
        self._update_sync_store(broker, 'POST')
    return HTTPNoContent(request=req)
