'Tell all cells to sync instance info.'

@extensions.expected_errors((400, 501))
@common.check_cells_enabled
@validation.schema(cells.sync_instances)
def sync_instances(self, req, body):

    context = req.environ['nova.context']
    context.can((cells_policies.POLICY_ROOT % 'sync_instances'))
    project_id = body.pop('project_id', None)
    deleted = body.pop('deleted', False)
    updated_since = body.pop('updated_since', None)
    if isinstance(deleted, six.string_types):
        deleted = strutils.bool_from_string(deleted, strict=True)
    self.cells_rpcapi.sync_instances(context, project_id=project_id, updated_since=updated_since, deleted=deleted)
