From: Eric Harney Date: Tue, 27 May 2014 14:11:53 +0000 (-0400) Subject: Fix ISER scan retry option X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=571ac18e7c4109fc9728a0ee27f04887f1d8aeea;p=openstack-build%2Fcinder-build.git Fix ISER scan retry option The 'num_iscsi_scan_tries' option was renamed to 'num_volume_device_scan_tries'. Remove it from the test where the deprecated name is referenced since it is not used there anyway. Fix the ISER driver to set the new config field rather than the old one. Presumably this made the num_iser_scan_tries option not work since only the new field is passed to the brick connector. Closes-Bug: #1323741 Change-Id: I13ac4cce10894b541054fbda719bbc5fd555e3c1 --- diff --git a/cinder/tests/test_volume.py b/cinder/tests/test_volume.py index a0016af73..34fd46718 100644 --- a/cinder/tests/test_volume.py +++ b/cinder/tests/test_volume.py @@ -3046,7 +3046,6 @@ class ISCSITestCase(DriverTestCase): def setUp(self): super(ISCSITestCase, self).setUp() self.configuration = mox.MockObject(conf.Configuration) - self.configuration.num_iscsi_scan_tries = 3 self.configuration.iscsi_num_targets = 100 self.configuration.iscsi_target_prefix = 'iqn.2010-10.org.openstack:' self.configuration.iscsi_ip_address = '0.0.0.0' diff --git a/cinder/volume/driver.py b/cinder/volume/driver.py index 56c92ba91..0852e29ca 100644 --- a/cinder/volume/driver.py +++ b/cinder/volume/driver.py @@ -939,7 +939,7 @@ class ISERDriver(ISCSIDriver): def __init__(self, *args, **kwargs): super(ISERDriver, self).__init__(*args, **kwargs) # for backward compatibility - self.configuration.num_iscsi_scan_tries = \ + self.configuration.num_volume_device_scan_tries = \ self.configuration.num_iser_scan_tries self.configuration.iscsi_num_targets = \ self.configuration.iser_num_targets