nova/nova/api
Mohammed Naser 6bd7e8a958 Use unique consumer_id when doing online data migration
If there are multiple consumers having allocations to the same
resource provider, with different classes, it will attempt
multiple INSERTs with the same consumer_id which is not allowed
because of the database constraints.

This patch adds a simple GROUP BY in order to ensure that the
database server only provides us with unique values to avoid
trying to INSERT duplicate values.

Conflicts:
      nova/tests/functional/api/openstack/placement/db/test_consumer.py

NOTE(mriedem): The conflict is due to not having change
I7f5f08691ca3f73073c66c29dddb996fb2c2b266 in Rocky.

Change-Id: I1acba5e65cd562472f29e354c6077f82844fa87d
Closes-Bug: #1798163
(cherry picked from commit 730936e535)
2018-10-17 09:24:13 -04:00
..
ec2 delete more i18n log markers 2017-03-21 07:37:21 -04:00
metadata metadata: add vf_trusted field to device metadata 2018-05-31 13:55:10 -04:00
openstack Use unique consumer_id when doing online data migration 2018-10-17 09:24:13 -04:00
validation Use hard coded values in schema than reference 2018-07-11 01:34:46 +00:00
__init__.py Remove unused copyright from nova.api.__init__ 2014-01-10 16:24:50 +08:00
auth.py Refactor WSGI apps and utils to limit imports 2018-03-06 22:05:12 +00:00
compute_req_id.py Migrate to oslo request_id middleware - mv 2.46 2017-05-27 10:11:44 +00:00
manager.py Only setup iptables for metadata if using nova-net 2017-07-20 00:00:22 +00:00
wsgi.py Refactor WSGI apps and utils to limit imports 2018-03-06 22:05:12 +00:00