From: Aviram Bar-Haim Date: Thu, 2 Apr 2015 14:37:04 +0000 (+0300) Subject: Fix ISCSIDriver initialized connection volume type X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=15b17071629a72e5e23340ba85fc0538a61541eb;p=openstack-build%2Fcinder-build.git Fix ISCSIDriver initialized connection volume type ISCSIDriver initialize connection is a duplicated function left in kilo to serve drivers that don't use the new targets model. In Kilo there is a new parameter of iscsi_protocol, that is set to iscsi by default and can be changed to iser in order to enable RDMA. In order support RDMA in drivers that still inherit from ISCSIDriver, driver_volume_type should be set to iscsi_protocol parameter value instead of a hard coded value until this function duplication will be solved. Closes-Bug: #1438833 Change-Id: If51ff933b75bf475c779d2599776f8a83acc08e5 --- diff --git a/cinder/volume/driver.py b/cinder/volume/driver.py index 474d80cec..5e4a70ce1 100644 --- a/cinder/volume/driver.py +++ b/cinder/volume/driver.py @@ -1572,7 +1572,8 @@ class ISCSIDriver(VolumeDriver): # this base class and use this init data iscsi_properties = self._get_iscsi_properties(volume) return { - 'driver_volume_type': 'iscsi', + 'driver_volume_type': + self.configuration.safe_get('iscsi_protocol'), 'data': iscsi_properties }