]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
VolMgr: reschedule only when filter_properties has retry
authorZhiteng Huang <zhithuang@ebaysf.com>
Fri, 17 Apr 2015 16:34:59 +0000 (00:34 +0800)
committerZhiteng Huang <zhithuang@ebaysf.com>
Mon, 20 Apr 2015 04:54:34 +0000 (12:54 +0800)
commit651bab00f7c06ed5e018526f3cbc38e12177bcfa
treec1907e8957332c2aa9519690fe1938550696ec96
parentae6c589c52557988e24b5ee8005d8f81564a6068
VolMgr: reschedule only when filter_properties has retry

In the task flow for volume manager, create_volume tasks, volume gets
reschedule even when scheduler doesn't indicate so.  The problem is
the flow should not only check 'allow_reschedule' and 'request_specs',
but also (more importantly) filter_properties['retry'], which is
populated by scheduler if schedule_max_attempts is set to > 1.  This
checks was there before taskflow was introduced, but somehow the
migration missed the check for filter_properties['retry'].

This change adds back the check, so scheduler_max_attempts won't be
treated like scheduler_max_attempts = infinite.

Change-Id: Ia873617b22a2d86662ea8ea2fec5aae7f54a2058
Closes-bug: #1445561
(cherry picked from commit 217f4dfb13714f583deeaeded66d36fb558e4b02)
cinder/tests/test_volume.py
cinder/volume/flows/manager/create_volume.py