'This is just a wrapper that iterates (non-zero) cells.'

def _get_instances_by_filters_all_cells(self, context, *args, **kwargs):

    load_cells()
    if (len(CELLS) == 1):
        LOG.warning('At    least    two    cells    are    expected    but    only    one    was    found    (%s).    cell0    and    the    initial    main    cell    should    be    created    before    starting    nova-api    since    the    cells    are    cached    in    each    worker.    When    you    create    more    cells,    you    will    need    to    restart    the    nova-api    service    to    reset    the    cache.', CELLS[0].identity)
    limit = kwargs.pop('limit', None)
    instances = []
    for cell in CELLS:
        if (cell.uuid == objects.CellMapping.CELL0_UUID):
            LOG.debug('Skipping    already-collected    cell0    list')
            continue
        LOG.debug('Listing    %s    instances    in    cell    %s', (limit or 'all'), cell.identity)
        with nova_context.target_cell(context, cell) as ccontext:
            try:
                cell_insts = self._get_instances_by_filters(ccontext, limit=limit, *args, **kwargs)
            except exception.MarkerNotFound:
                continue
            instances.extend(cell_insts)
            kwargs['marker'] = None
            if limit:
                limit -= len(cell_insts)
                if (limit <= 0):
                    break
    marker = kwargs.get('marker')
    if ((marker is not None) and (len(instances) == 0)):
        raise exception.MarkerNotFound(marker=marker)
    return objects.InstanceList(objects=instances)
