commit 6bd7e8a958f53e2288b41a27528a008e3cfb2802
Author: Mohammed Naser <email address hidden>
Date: Tue Oct 16 19:54:40 2018 +0200
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.
Reviewed: https:/ /review. openstack. org/611315 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=6bd7e8a958f 53e2288b41a2752 8a008e3cfb2802
Committed: https:/
Submitter: Zuul
Branch: stable/rocky
commit 6bd7e8a958f53e2 288b41a27528a00 8e3cfb2802
Author: Mohammed Naser <email address hidden>
Date: Tue Oct 16 19:54:40 2018 +0200
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/functiona l/api/openstack /placement/ db/test_ consumer. py
NOTE(mriedem): The conflict is due to not having change a3f73073c66c29d ddb996fb2c2b266 in Rocky.
I7f5f08691c
Change-Id: I1acba5e65cd562 472f29e354c6077 f82844fa87d 7c76d4f27649a16 d8cf05efc9)
Closes-Bug: #1798163
(cherry picked from commit 730936e535e6712