← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1767303] [NEW] Scheduler connects to all cells DBs to gather compute nodes info

 

Public bug reported:

The scheduler host.manager connects to all cells DBs to get compute node
info even if only a subset of compute nodes uuids are given by
placement.

This has a performance impact in large cloud deployments with several
cells.

Also related with:
https://review.openstack.org/#/c/539617/9/nova/scheduler/host_manager.py

{code}
def _get_computes_for_cells(self, context, cells, compute_uuids=None)
        for cell in cells:
            LOG.debug('Getting compute nodes and services for cell %(cell)s',
                      {'cell': cell.identity})
            with context_module.target_cell(context, cell) as cctxt:
                if compute_uuids is None:
                    compute_nodes[cell.uuid].extend(
                        objects.ComputeNodeList.get_all(cctxt))
                else:
                    compute_nodes[cell.uuid].extend(
                        objects.ComputeNodeList.get_all_by_uuids(
                            cctxt, compute_uuids))
                services.update(
                    {service.host: service
                     for service in objects.ServiceList.get_by_binary(
                             cctxt, 'nova-compute',
                             include_disabled=True)})
        return compute_nodes, services
{code}

** Affects: nova
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1767303

Title:
  Scheduler connects to all cells DBs to gather compute nodes info

Status in OpenStack Compute (nova):
  New

Bug description:
  The scheduler host.manager connects to all cells DBs to get compute
  node info even if only a subset of compute nodes uuids are given by
  placement.

  This has a performance impact in large cloud deployments with several
  cells.

  Also related with:
  https://review.openstack.org/#/c/539617/9/nova/scheduler/host_manager.py

  {code}
  def _get_computes_for_cells(self, context, cells, compute_uuids=None)
          for cell in cells:
              LOG.debug('Getting compute nodes and services for cell %(cell)s',
                        {'cell': cell.identity})
              with context_module.target_cell(context, cell) as cctxt:
                  if compute_uuids is None:
                      compute_nodes[cell.uuid].extend(
                          objects.ComputeNodeList.get_all(cctxt))
                  else:
                      compute_nodes[cell.uuid].extend(
                          objects.ComputeNodeList.get_all_by_uuids(
                              cctxt, compute_uuids))
                  services.update(
                      {service.host: service
                       for service in objects.ServiceList.get_by_binary(
                               cctxt, 'nova-compute',
                               include_disabled=True)})
          return compute_nodes, services
  {code}

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1767303/+subscriptions