Fixed an error when caching multiple images in aggregate
Because in the process of judging whether the image id is Duplicate,there is only deduplication without sorting, so no duplicate image error is judged as duplicate and an error "Duplicate images in request" is reported.
Now it is changed to sort after deduplication and then compare.
Reviewed: https:/ /review. opendev. org/c/openstack /nova/+ /894288 /opendev. org/openstack/ nova/commit/ aa500fbb31d2f71 29c048460e57a3d ff229cabc8
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit aa500fbb31d2f71 29c048460e57a3d ff229cabc8
Author: liwenjian <email address hidden>
Date: Fri Sep 8 17:14:38 2023 +0800
Fixed an error when caching multiple images in aggregate
Because in the process of judging whether the image id is Duplicate,there is only deduplication without sorting, so no duplicate image error is judged as duplicate and an error "Duplicate images in request" is reported.
Now it is changed to sort after deduplication and then compare.
Two unit test cases were added to verify the fix
Related-Bug: #2034702 4f4c99d534a6cf8 ee7dc0ed4b7
Change-Id: I300a3e29ba5658