RBD: Run flatten in a different thread when cloning a volume
The current implementation of create_cloned_volume calls flatten
directly, and this makes whole thread of cinder-volume blocked by that
flatten call. This causes heartbeat timeout in RabbitMQ when cloning
a volume with rbd backend.
This patch makes sure that flatten is executed in a different thread,
to allow heatbeat thread to run while flattening a rbd image.
Closes-Bug: #1898918
Change-Id: I9f28260008117abcebfc96dbe69bf892f5cd14fe
(cherry picked from commit bafe440b9418a1e3acd00456872d4d97a9c64c61)
Reviewed: https:/ /review. opendev. org/758003 /git.openstack. org/cgit/ openstack/ cinder/ commit/ ?id=f1521d82d94 1e711f6ef248a7e b81f096de8135f
Committed: https:/
Submitter: Zuul
Branch: stable/victoria
commit f1521d82d941e71 1f6ef248a7eb81f 096de8135f
Author: Takashi Kajinami <email address hidden>
Date: Wed Oct 7 09:55:32 2020 +0900
RBD: Run flatten in a different thread when cloning a volume
The current implementation of create_ cloned_ volume calls flatten
directly, and this makes whole thread of cinder-volume blocked by that
flatten call. This causes heartbeat timeout in RabbitMQ when cloning
a volume with rbd backend.
This patch makes sure that flatten is executed in a different thread,
to allow heatbeat thread to run while flattening a rbd image.
Closes-Bug: #1898918 bcebfc96dbe69bf 892f5cd14fe 3acd00456872d4d 97a9c64c61)
Change-Id: I9f28260008117a
(cherry picked from commit bafe440b9418a1e