]> review.fuel-infra Code Review - openstack-build/cinder-build.git/log
openstack-build/cinder-build.git
8 years agoFixed logging for oslo versioned objects
Szymon Borkowski [Tue, 12 Jan 2016 10:32:22 +0000 (11:32 +0100)]
Fixed logging for oslo versioned objects

Earlier, when we wanted to log a message with an object as a parameter,
obj_attr_is_set method used to check name parameter, which was a wrong
approach. The reason was, that the oslo logger, when received a
versioned object as a resource parameter, is trying to get the 'name'
parameter, which is a property, so the obj_attr_is_set method will
return False and the logger will try to get the 'type' parameter, which
does not exist in some versioned objects (please take a look at
oslo.logging code [1]).

Now, when the parameter's name is present in obj_extra_fields
dict, we avoid calling obj_attr_is_set and simply get() it.

The other cause was a difference between fields names: size (in volume
object) and volume_size (in snapshot object), and inproper condition
statement in lvm driver.

[1] goo.gl/YffLcK

Change-Id: Id92d58b4ccced907cc6e3e59d9e71650a459b4a8
Closes-Bug: 1501521

8 years agoMerge "ScaleIO QoS Support"
Jenkins [Tue, 9 Feb 2016 03:56:04 +0000 (03:56 +0000)]
Merge "ScaleIO QoS Support"

8 years agoMerge "Port objects unit tests to Python 3"
Jenkins [Tue, 9 Feb 2016 03:29:14 +0000 (03:29 +0000)]
Merge "Port objects unit tests to Python 3"

8 years agoMerge "IBM XIV/DS8K: Implements Replication V2"
Jenkins [Tue, 9 Feb 2016 01:57:35 +0000 (01:57 +0000)]
Merge "IBM XIV/DS8K: Implements Replication V2"

8 years agoScaleIO QoS Support
Xing Yang [Sat, 21 Nov 2015 14:17:51 +0000 (09:17 -0500)]
ScaleIO QoS Support

This patch adds QoS support to the ScaleIO driver by
using Cinder QoS specs.

Also refactored logging and fixed formatting errors.

DocImpact
Change-Id: I7608192b91010a538027ab456c5ff5bba569214c
Implements: blueprint scaleio-qos-support

8 years agoMerge "Allow for eradicating Pure volumes on Cinder delete"
Jenkins [Mon, 8 Feb 2016 21:08:10 +0000 (21:08 +0000)]
Merge "Allow for eradicating Pure volumes on Cinder delete"

8 years agoPort objects unit tests to Python 3
Victor Stinner [Tue, 26 Jan 2016 14:48:34 +0000 (15:48 +0100)]
Port objects unit tests to Python 3

* BaseObjectsTestCase._compare(): replace hasattr() with getattr()
  and a white list of expected exceptions. On Python 2, hasattr()
  ignores *all* exceptions and so may hide real bugs.
* Mocks: except a call to obj.__bool__() rather than
  obj.__nonzero__() on Python 3. bool(obj) now calls obj.__bool__()
  on Python 3.
* Replace dict.keys() with list(dict.keys()) to get a list on Python
  3. On Python 3, dict.keys() now returns a view.
* JSON/base64:

  * Replace jsonutils.dumps() with jsonutils.dump_as_bytes() to get
    JSON as bytes
  * Replace base64.encodestring() with oslo_serialization.base64.encode_as_text() to get
    base64 as bytes
  * Replace base64.decodestring() with
    oslo_serialization.base64.decode_as_text() to accept Unicode and
    return Unicode

* tests-py3.txt: add cinder.tests.unit.objects.test_* (11 files)

Partial-Implements: blueprint cinder-python3
Change-Id: I9ce7753eb947bf9a5c91e643f5c65156c8e3f7cc

8 years agoMerge "Clean uploading volume when c-vol restarts"
Jenkins [Sun, 7 Feb 2016 05:51:52 +0000 (05:51 +0000)]
Merge "Clean uploading volume when c-vol restarts"

8 years agoUpdated from global requirements
OpenStack Proposal Bot [Sat, 6 Feb 2016 23:00:27 +0000 (23:00 +0000)]
Updated from global requirements

Change-Id: I2a195d5905446efc53da759246f528c9653972b4

8 years agoMerge "Bootable filter for listening volumes from CLI"
Jenkins [Sat, 6 Feb 2016 06:34:12 +0000 (06:34 +0000)]
Merge "Bootable filter for listening volumes from CLI"

8 years agoMerge "LeftHand: Implement un/manage snapshot support"
Jenkins [Sat, 6 Feb 2016 06:32:32 +0000 (06:32 +0000)]
Merge "LeftHand: Implement un/manage snapshot support"

8 years agoMerge "VNX: Replication V2 support(managed)"
Jenkins [Sat, 6 Feb 2016 03:48:01 +0000 (03:48 +0000)]
Merge "VNX: Replication V2 support(managed)"

8 years agoMerge "Fix issue in hacking with underscore imports"
Jenkins [Sat, 6 Feb 2016 01:51:06 +0000 (01:51 +0000)]
Merge "Fix issue in hacking with underscore imports"

8 years agoMerge "Fix variable scope issue in try-except"
Jenkins [Sat, 6 Feb 2016 01:50:40 +0000 (01:50 +0000)]
Merge "Fix variable scope issue in try-except"

8 years agoMerge "DRBD: Compat for current DRBDmanage versions."
Jenkins [Sat, 6 Feb 2016 00:48:31 +0000 (00:48 +0000)]
Merge "DRBD: Compat for current DRBDmanage versions."

8 years agoLeftHand: Implement un/manage snapshot support
Anthony Lee [Wed, 9 Dec 2015 00:15:42 +0000 (16:15 -0800)]
LeftHand: Implement un/manage snapshot support

Implements support for managing and unmanaging snapshots to
the HPE LeftHand driver.

This patch now allows snapshots to be removed from OpenStack
management but still left on the LeftHand backend. Snapshots
on the LeftHand backend can also be managed by OpenStack.

DocImpact
Implements: blueprint lefthand-manage-unmanage-snapshot
Change-Id: Ic0048fd5da437cf8caddc166cf60ec035def39aa

8 years agoMerge "Updated from global requirements"
Jenkins [Fri, 5 Feb 2016 09:05:30 +0000 (09:05 +0000)]
Merge "Updated from global requirements"

8 years agoMerge "Remove useless unit tests mock in Huawei driver"
Jenkins [Fri, 5 Feb 2016 06:19:57 +0000 (06:19 +0000)]
Merge "Remove useless unit tests mock in Huawei driver"

8 years agoUpdated from global requirements
OpenStack Proposal Bot [Fri, 5 Feb 2016 05:06:51 +0000 (05:06 +0000)]
Updated from global requirements

Change-Id: I0cf8ca5627ce99997980bb06ad463a1a0b0e259e

8 years agoAllow for eradicating Pure volumes on Cinder delete
Patrick East [Tue, 2 Feb 2016 19:08:39 +0000 (11:08 -0800)]
Allow for eradicating Pure volumes on Cinder delete

This change adds in a config option which, when enabled, will cause
the Pure Storage volume drivers to eradicate volumes, snapshots, and
protection groups on delete for their Cinder counterpart.

With this config enabled an admin will NOT be able to recover data once
objects are deleted. By default the new config option is disabled and
volumes, snapshots, and protection group snapshots will be retained
pending eradication where they can be recovered for a period of time.

DocImpact
Closes-Bug: #1537187

Change-Id: Ib3656bb64e5104f6bd05d28535cf91a46a038b55

8 years agoMerge "Don't create cgsnapshot if cg is empty"
Jenkins [Thu, 4 Feb 2016 21:13:33 +0000 (21:13 +0000)]
Merge "Don't create cgsnapshot if cg is empty"

8 years agoMerge "Imported Translations from Zanata"
Jenkins [Thu, 4 Feb 2016 19:15:57 +0000 (19:15 +0000)]
Merge "Imported Translations from Zanata"

8 years agoMerge "mock time.sleep in Broadcom unit test"
Jenkins [Thu, 4 Feb 2016 17:38:49 +0000 (17:38 +0000)]
Merge "mock time.sleep in Broadcom unit test"

8 years agoMerge "Tests: Strengthen assertFalse assertions"
Jenkins [Thu, 4 Feb 2016 17:36:21 +0000 (17:36 +0000)]
Merge "Tests: Strengthen assertFalse assertions"

8 years agoMerge "3PAR fix driver to work with image cache"
Jenkins [Thu, 4 Feb 2016 16:55:45 +0000 (16:55 +0000)]
Merge "3PAR fix driver to work with image cache"

8 years agoFix issue in hacking with underscore imports
Marc Koderer [Thu, 4 Feb 2016 12:43:33 +0000 (13:43 +0100)]
Fix issue in hacking with underscore imports

Hacking rule for underscore imports _() are not working correctly.
It also matches _.* imports like "import _LE"

See review: https://review.openstack.org/#/c/270754/

Closes-bug: 1541780
Change-Id: Ibdef35e1896882a8dfe3165dba989255639e61ba

8 years agoDRBD: Compat for current DRBDmanage versions.
Philipp Marek [Thu, 4 Feb 2016 13:47:39 +0000 (14:47 +0100)]
DRBD: Compat for current DRBDmanage versions.

The to-be-1.0 versions may provide additional data via a DM_INFO
tag; but as older versions don't have that (yet), we need to be
careful when asking for its value.

Change-Id: Ic800755d74ef22ec48bd3b8cd8000c610221bb52

8 years agoFix variable scope issue in try-except
Accela Zhao [Thu, 4 Feb 2016 02:11:09 +0000 (18:11 -0800)]
Fix variable scope issue in try-except

Below piece of code in cinder.backup.api.API.create does not handle
the scope of variable 'backup' properly. In general variable used in
except clause has larger scope than what is in try clause.

```
    try:
        ...
        backup = objects.Backup(context=context, **kwargs)
        backup.create()
        ...
    except Exception:
            ...
            backup.destroy()
            ...
```

The first problem: if object.Backup.__init__ raises exception,
variable 'backup' won't be assigned. However the cleanup code invokes
backup.destroy(), which results in an UnboundLocalError. The original
exception of __init__ is dropped, instead UnboundLocalError is raised
up-level. I know that for now objects.Backup.__init__ doesn't have
chance to raise exception, but when writing code we should not rely
on such assumption.

The second problem: backup.create() invokes DB. If an DB exception is
raised, backup.id won't be assigned. Any access to backup.id will
result in an "NotImplementedError: Cannot load 'id' in the base
class". However, when cleaning up, the backup.destroy() does access
backup.id. So we have the similar problem as the first one, and the
original exception is overrode by NotImplementedError.

This patch fixes it by adding a first-assignment outside try clause,
and add a safe check in except clause. The added test cases, if run
on the original code, it will show how the above problem occurs.

Closes-Bug: #1541745
Change-Id: I0e55c342ac489ff1ef27c0597b6dcba588778a04

8 years agoImported Translations from Zanata
OpenStack Proposal Bot [Thu, 4 Feb 2016 06:38:33 +0000 (06:38 +0000)]
Imported Translations from Zanata

For more information about this automatic import see:
https://wiki.openstack.org/wiki/Translations/Infrastructure

Change-Id: I1388c56b2cf7d0bcaef3c8d1ea2c407fc46e8a2e

8 years agoBootable filter for listening volumes from CLI
Sheel Rana [Wed, 3 Feb 2016 18:30:11 +0000 (00:00 +0530)]
Bootable filter for listening volumes from CLI

Currently cinder treats all values passed to it as True
for bootable filter in volume GET call.

For ex, if bootable=invalid, it converts it into True being
bootable as boolean value in db table 'volume'.

Need to update filtering functionality in cinder to address
'True' and 'False' values seperately.

Existing behavior will be kept same.
Only True/False/true/false input handling is done to treat
true/false seperately
(In current behavior, whatever input is passed for boolean
parameter, cinder convetrs it to True)

Implements : blueprint select-volume-through-bootable-option

Closes-Bug: #1535749

Change-Id: I1f1ec20441b28e01bf07bc4f60d848b653e58d58

8 years agoClean uploading volume when c-vol restarts
LisaLi [Wed, 3 Feb 2016 03:10:39 +0000 (11:10 +0800)]
Clean uploading volume when c-vol restarts

This patch is to clean up the state of uploading volumes to
original status when volume service restarts.

Change-Id: I0f49261f11efff835fa2e173bab5c823ca8d7d6e
Closes-bug: #1541175

8 years agoMerge "EMC VMAX - Fix for last volume in VMAX3 storage group"
Jenkins [Wed, 3 Feb 2016 23:05:42 +0000 (23:05 +0000)]
Merge "EMC VMAX - Fix for last volume in VMAX3 storage group"

8 years agoMerge "Imported Translations from Zanata"
Jenkins [Wed, 3 Feb 2016 23:02:29 +0000 (23:02 +0000)]
Merge "Imported Translations from Zanata"

8 years agomock time.sleep in Broadcom unit test
Tom Barron [Wed, 3 Feb 2016 22:14:23 +0000 (17:14 -0500)]
mock time.sleep in Broadcom unit test

TestBrcdHttpFCZoneClient.test_post_zone_data() invokes
BrcdHTTPFCZoneClient.post_zone_data(), which in turn
has a loop around its connect() method inside which there
is a sleep().  Without time.sleep() mocked out, the test
runs 7s on my laptop.

This change mocks out time.sleep() in the test so that
it now runs in .6s.

Change-Id: Ib4c3a12b048a68d2c2db722c089eb04dd7d8c8ef

8 years agoDon't create cgsnapshot if cg is empty
Accela Zhao [Wed, 3 Feb 2016 07:19:45 +0000 (23:19 -0800)]
Don't create cgsnapshot if cg is empty

If we create cgsnapshot from an empty consistencygroup, it fails
with "Consistency group is empty. No cgsnapshot will be created".
However, a cgsnapshot object is still created in DB.

This is because in cinder/consistencygroup/api.py::_create_cgsnapshot,
we create cgsnapshot object before we test whether the corresponding
consistencygroup is empy.

This patch fixes this problem by moving the creation of cgsnapshot
object to after the test of whether consistencygroup is empty.

Change-Id: I09500ab1cf19b28591668a3fed6834d1a73ad176
Closes-Bug: #1535979

8 years agoImported Translations from Zanata
OpenStack Proposal Bot [Wed, 3 Feb 2016 07:04:10 +0000 (07:04 +0000)]
Imported Translations from Zanata

For more information about this automatic import see:
https://wiki.openstack.org/wiki/Translations/Infrastructure

Change-Id: Ife555940fe3df05e895c7a2229b0e59700b1a1b9

8 years agoFix the replication spelling in message
venkatamahesh [Wed, 3 Feb 2016 06:15:11 +0000 (11:45 +0530)]
Fix the replication spelling in message

Changed replicaiton to replication

Change-Id: I58cd74b644e976d49b72075eed347c8cce4c4352

8 years agoMerge "LeftHand: Implement v2 replication (unmanaged)"
Jenkins [Wed, 3 Feb 2016 06:01:57 +0000 (06:01 +0000)]
Merge "LeftHand: Implement v2 replication (unmanaged)"

8 years agoMerge "Remove deprecated options from NFS driver"
Jenkins [Wed, 3 Feb 2016 03:33:45 +0000 (03:33 +0000)]
Merge "Remove deprecated options from NFS driver"

8 years agoMerge "Replication V2 for Pure Storage"
Jenkins [Wed, 3 Feb 2016 03:32:20 +0000 (03:32 +0000)]
Merge "Replication V2 for Pure Storage"

8 years ago3PAR fix driver to work with image cache
Walter A. Boring IV [Thu, 10 Sep 2015 18:19:24 +0000 (11:19 -0700)]
3PAR fix driver to work with image cache

This patch fixes the problem with the 3PAR not
working with the generic image cache.

In order to do the image cache, the 3PAR has to create a
temporary snapshot of the volume being cloned.  Then the
background cloning is against the temporary snapshot.
The problem is, the temporary snapshot stays around.
We try to account for this temporary snapshot in
the delete volume action.

We also bump the minimum required python-3parclient
version to 4.1.0, which has the new getVolumeSnapshots
API call required to make this all work.

Change-Id: I6dea01ce07387990aa38bd5106b51504739b3a6e
Closes-Bug: #1491088

8 years agoMerge "Improve logging for volume detach"
Jenkins [Tue, 2 Feb 2016 06:25:22 +0000 (06:25 +0000)]
Merge "Improve logging for volume detach"

8 years agoUpdated from global requirements
OpenStack Proposal Bot [Mon, 1 Feb 2016 13:36:35 +0000 (13:36 +0000)]
Updated from global requirements

Change-Id: I026436e02d8fae0501fe948558527a7c635d3345

8 years agoImprove logging for volume detach
Vipin Balachandran [Mon, 1 Feb 2016 12:10:00 +0000 (04:10 -0800)]
Improve logging for volume detach

Currently the volume manager doesn't log the instance ID during
volume detach. This is missing in cinder-api log as well. This
patch adds a log statement to print a message with volume ID and
instance ID before calling driver detach.

Change-Id: I6e765124c4e737e64cff39ec82cb81749bca28ab

8 years agoRemove useless unit tests mock in Huawei driver
Wilson Liu [Sat, 23 Jan 2016 02:21:41 +0000 (10:21 +0800)]
Remove useless unit tests mock in Huawei driver

There are some useless ut mocks in Huawei driver,
we'd better to cleanup them.

Also we did some other code cleanup:
1. Cleanup the return value when delete_volume and extend_volume.
2. Check whether the LUN exists in a LUN group firstly besause
   this case is more likely to happen than other cases.

Closes-Bug: #1535697
Change-Id: Ia3ea1d666623cf7c37b6be3fbc55282229293ea8

8 years agoMerge "Huawei: Balanced FC port selection when zoning"
Jenkins [Sun, 31 Jan 2016 20:43:21 +0000 (20:43 +0000)]
Merge "Huawei: Balanced FC port selection when zoning"

8 years agoMerge "Pin RPC and object version to lowest running"
Jenkins [Sat, 30 Jan 2016 21:14:52 +0000 (21:14 +0000)]
Merge "Pin RPC and object version to lowest running"

8 years agoMerge "Report RPC and objects versions"
Jenkins [Sat, 30 Jan 2016 21:14:30 +0000 (21:14 +0000)]
Merge "Report RPC and objects versions"

8 years agoEMC VMAX - Fix for last volume in VMAX3 storage group
Helen Walsh [Wed, 11 Nov 2015 22:09:59 +0000 (22:09 +0000)]
EMC VMAX - Fix for last volume in VMAX3 storage group

This patch fixes bug in the deletion the last volume in a
storage group for the VMAX3. If a masking view did not exist
we tried to get an instance of it which threw an exception.
Now we handle both scenarios correctly.

Closes-Bug: #1512796

Change-Id: Ideb2aaffe4fbc1ae2137d569d7b137ac0edef573

8 years agoMerge "Add missing RPC calls versions to rpcapi modules"
Jenkins [Sat, 30 Jan 2016 20:26:48 +0000 (20:26 +0000)]
Merge "Add missing RPC calls versions to rpcapi modules"

8 years agoMerge "Remove invalid NetApp QoS keys"
Jenkins [Sat, 30 Jan 2016 07:12:56 +0000 (07:12 +0000)]
Merge "Remove invalid NetApp QoS keys"

8 years agoMerge "XtremIO: Set the location of a CA certificate"
Jenkins [Fri, 29 Jan 2016 20:52:30 +0000 (20:52 +0000)]
Merge "XtremIO: Set the location of a CA certificate"

8 years agoMerge "Storwize: Add force flag on vdisk mapping call"
Jenkins [Fri, 29 Jan 2016 18:42:42 +0000 (18:42 +0000)]
Merge "Storwize: Add force flag on vdisk mapping call"

8 years agoMerge "Adds HTTPS southbound connector for Brocade FC Zone Driver"
Jenkins [Fri, 29 Jan 2016 15:51:47 +0000 (15:51 +0000)]
Merge "Adds HTTPS southbound connector for Brocade FC Zone Driver"

8 years agoMerge "EMC VMAX - VMAX driver failing to remove zones"
Jenkins [Fri, 29 Jan 2016 15:50:04 +0000 (15:50 +0000)]
Merge "EMC VMAX - VMAX driver failing to remove zones"

8 years agoPin RPC and object version to lowest running
Michał Dulko [Thu, 14 Jan 2016 19:57:12 +0000 (20:57 +0100)]
Pin RPC and object version to lowest running

This commit adds detection and pinning to lowest RPC API version to all
rpcapi modules. The version pin is determined by a DB call done once per
service lifetime thanks to caching. Handling the compatibility is
guaranteed by oslo.messaging and our shims in rpcapi modules.

To achieve o.vo compatibility, a similar approach is implemented. Custom
oslo.messaging serializer is implemented that backports objects to the
lowest running version on sending.

During the process of upgrade it may happen that manager receives an
object in the version lower than current one. Handling of such
situations is up to the manager and it should do that explicitely by
checking obj.VERSION.

The patch also adds required methods to db.api and Service object.

Co-Authored-By: Thang Pham <thang.g.pham@gmail.com>
Change-Id: I649892da64f9734928a6cf0f004a369aa7aa375f
Partial-Implements: blueprint rpc-object-compatibility

8 years agoReport RPC and objects versions
Michał Dulko [Thu, 14 Jan 2016 18:37:18 +0000 (19:37 +0100)]
Report RPC and objects versions

While doing a rolling upgrade we will have services running in various
versions. In order to determine how to downgrade the RPC request and
payload (objects) to the lowest common version we need to actually
report versions of RPC servers (managers).

This commit implements such reporting in generic cinder.service module.
It is using DB columns that were merged in Liberty to save this
information.

To have a single version string identify a set of o.vo versions we need
to have dictionary with objects versions history. In that purpose a
dict-like CinderObjectVersionsHistory class and OBJ_VERSIONS instance of
it is added to cinder.objects.base. A unit test enforcing bumping the
versions is also included with the patch.

Change-Id: Ic3b57450e9d6f155a7eb805d224389f5f09eae18
Partial-Implements: blueprint rpc-object-compatibility

8 years agoAdd missing RPC calls versions to rpcapi modules
Michał Dulko [Wed, 13 Jan 2016 15:18:45 +0000 (16:18 +0100)]
Add missing RPC calls versions to rpcapi modules

Some RPC calls in rpcapi modules are not passing version indicators to
the RPC client. The RPC call version should be indicated explicitely
because otherwise it gets defaulted to the latest one or '1.0'. This
creates a set of problem in maintaining RPC API backward compatibility.

This commit changes these calls to point to the right versions according
to git history and version comments in rpcapi files.

Change-Id: Ib05d9748e18589df5a67f7b7ea668394cc8df769
Related-Blueprint: rpc-object-compatibility

8 years agoHuawei: Balanced FC port selection when zoning
Wilson Liu [Thu, 24 Dec 2015 04:57:56 +0000 (12:57 +0800)]
Huawei: Balanced FC port selection when zoning

Currently we always select the first two FC ports
from every controller when zoning, the rest FC ports
of the controller will never be selected. This patch
will calculate each port's load and select the first
two smallest load ports.

Implements: blueprint huawei-balanced-fc-port-selection
Change-Id: Ie9045e0d12b7cdb920b3886545772b60727cc64e

8 years agoVNX: Replication V2 support(managed)
peter_wang [Sat, 10 Oct 2015 09:23:17 +0000 (05:23 -0400)]
VNX: Replication V2 support(managed)

This patch implements the managed side of replication V2 in VNX driver.

cinder.conf should follow below examples:

[vnx_cinder]
...
replication_device = target_device_id:<vnx serial number>,
                     managed_backend_name:
                     <host>@<backend_name>#<pool_name>,
                     san_ip:192.168.1.2,
                     san_login:admin,
                     san_password:admin,
                     storage_vnx_authentication_type:global,
                     storage_vnx_security_file_dir:/home/stack
...

Supported operation:
* create volume
* disable replication
* enable replication
* failover replication
* clone volume
* create volume from snapshot

VNX cinder driver also supports failover back and forth

NOTE: you can only place one replication_device for each backend since
VNX driver only supports 1:1 fanout ratio. Only synchronized replication
is supported in this patch.

DocImpact
Change-Id: Ica47700b0f251bb4f7af5500f36416ddf91de9c5
Implements: blueprint vnx-replication-v2

8 years agoMerge "Run flake8 also on cinder/common"
Jenkins [Fri, 29 Jan 2016 05:43:09 +0000 (05:43 +0000)]
Merge "Run flake8 also on cinder/common"

8 years agoMerge "Add pagination support to consistency group"
Jenkins [Fri, 29 Jan 2016 05:42:00 +0000 (05:42 +0000)]
Merge "Add pagination support to consistency group"

8 years agoMerge "Fix update_consistencygroup log info"
Jenkins [Fri, 29 Jan 2016 05:21:42 +0000 (05:21 +0000)]
Merge "Fix update_consistencygroup log info"

8 years agoMerge "Fix laggard cisco FC zone client unit tests"
Jenkins [Fri, 29 Jan 2016 05:21:17 +0000 (05:21 +0000)]
Merge "Fix laggard cisco FC zone client unit tests"

8 years agoAdds HTTPS southbound connector for Brocade FC Zone Driver
Pradeep Sathasivam [Thu, 21 May 2015 15:01:29 +0000 (20:31 +0530)]
Adds HTTPS southbound connector for Brocade FC Zone Driver

Set ssl verify to False for HTTPS.

Marked 'principal_switch_wwn' parameter from the config options as
deprecated.

DocImpact

Implements: blueprint brocade-zone-driver-virtualfabrics-support

Change-Id: I0b40b520580eaa6821c0af29abc6d2497d884ad2

8 years agoMerge "Fix thin provisioning flags in NetApp drivers"
Jenkins [Thu, 28 Jan 2016 20:05:34 +0000 (20:05 +0000)]
Merge "Fix thin provisioning flags in NetApp drivers"

8 years agoReplication V2 for Pure Storage
Daniel Wilson [Mon, 17 Aug 2015 22:46:13 +0000 (15:46 -0700)]
Replication V2 for Pure Storage

This implementation utilizes Pure Storage Protection Groups to
replicate volumes natively between Pure Storage backends.

Replication schedules can be set via config file options.
Replication targets are also set via config file options.

For example,
[puredriver-1]
volume_backend_name = puredriver-1
...
replication_device = target_device_id:<unique_array_id>,
                     managed_backend_name:puredriver-2,
                     san_ip:<ip_address>,
                     api_token:<authentication_token>
pure_replica_interval_default = 900
pure_replica_retention_short_term_default = 14400
pure_replica_retention_long_term_per_day_default = 3
pure_replica_retention_long_term_default = 7

replication_device describes the target array for replication. This can
be either another managed cinder backend or one not managed by cinder.

The above settings will cause a protection group to be created between
the two flash arrays. It will replicate any volumes placed in it with
settings that cause a volume to be replicated every 15 mins (900s).  All
snapshots will be kept for 4 hours (14400s).  Then 3 snapshots per day
will be kept for 7 days.

Note that replication-failover is supported from primary to any of
multiple secondary arrays, but subsequent replication-failover is
only supported back to the original primary.

DocImpact
Implements: bp pure-v2-replication
Change-Id: I69e567143b65e92f89969ff5036c4f242c17a1dd

8 years agoMerge "Remove redundant definition of 'deleted'"
Jenkins [Thu, 28 Jan 2016 06:07:38 +0000 (06:07 +0000)]
Merge "Remove redundant definition of 'deleted'"

8 years agoMerge "Huawei: Add manage/unmanage snapshot support"
Jenkins [Thu, 28 Jan 2016 05:14:28 +0000 (05:14 +0000)]
Merge "Huawei: Add manage/unmanage snapshot support"

8 years agoRemove redundant definition of 'deleted'
Sergey Gotliv [Wed, 27 Jan 2016 06:20:09 +0000 (08:20 +0200)]
Remove redundant definition of 'deleted'

Remove redundant definition of class variable 'deleted' from
models.Volume because it's already defined in the parent class
CinderBase.

Change-Id: I9fcd9ff1b99a8e018043fe61cd06059681fdb266

8 years agoFix update_consistencygroup log info
huyang [Wed, 27 Jan 2016 03:54:06 +0000 (11:54 +0800)]
Fix update_consistencygroup log info

In update_consistencygroup function,
the log info is inappropriate, so fix it.

Change-Id: I0de0c3ebdcf9da2d6e975027ebba519869e84c3b
Closes-Bug: #1538391

8 years agoMerge "Fix NFS driver unit test docstring"
Jenkins [Tue, 26 Jan 2016 11:44:45 +0000 (11:44 +0000)]
Merge "Fix NFS driver unit test docstring"

8 years agoHuawei: Add manage/unmanage snapshot support
chenzongliang [Sat, 12 Dec 2015 09:11:55 +0000 (17:11 +0800)]
Huawei: Add manage/unmanage snapshot support

Add manage/unmanage snapshot support for Huawei
drivers. Also implement the required
manage_existing_snapshot_get_size function.

DocImpact
Implements: blueprint huawei-manage-unmanage-snapshot

Change-Id: I05f8a750a745498c879d8c734e661d778528258c

8 years agoMerge "Adds friendly zone name support"
Jenkins [Tue, 26 Jan 2016 00:42:41 +0000 (00:42 +0000)]
Merge "Adds friendly zone name support"

8 years agoMerge "Disallow transferring volume in consistency group"
Jenkins [Tue, 26 Jan 2016 00:42:10 +0000 (00:42 +0000)]
Merge "Disallow transferring volume in consistency group"

8 years agoRemove deprecated options from NFS driver
Tom Barron [Tue, 19 Jan 2016 13:56:51 +0000 (08:56 -0500)]
Remove deprecated options from NFS driver

In the Liberty release, the NFS driver deprecated the 'nfs_used_ratio'
and 'nfs_oversubscription_ratio' configuration options since equivalent
common functionality is now provided across drivers by the scheduler-aware
'reserved_percentage' and 'max_over_sucscription_ratio' configuration
options.

This commit removes these deprecated options, tests for same, and
some Liberty code that proviced backwards compatibility with respect to
these options.

DocImpact

Change-Id: Ia3af9cbe69b2342649fe378aefe6ed1e46a82b19

8 years agoMerge "fix NFS driver max_over_subscription_ratio typo"
Jenkins [Mon, 25 Jan 2016 23:54:45 +0000 (23:54 +0000)]
Merge "fix NFS driver max_over_subscription_ratio typo"

8 years agoMerge "Fixing HNAS XML parser"
Jenkins [Mon, 25 Jan 2016 23:54:27 +0000 (23:54 +0000)]
Merge "Fixing HNAS XML parser"

8 years agoMerge "Fix torpid coordinator unit tests"
Jenkins [Mon, 25 Jan 2016 22:45:13 +0000 (22:45 +0000)]
Merge "Fix torpid coordinator unit tests"

8 years agoMerge "NetApp ONTAP - Reapply API tracing"
Jenkins [Mon, 25 Jan 2016 22:44:48 +0000 (22:44 +0000)]
Merge "NetApp ONTAP - Reapply API tracing"

8 years agoMerge "Fix sluggish rbd unit tests"
Jenkins [Mon, 25 Jan 2016 22:43:14 +0000 (22:43 +0000)]
Merge "Fix sluggish rbd unit tests"

8 years agoFixing HNAS XML parser
Erlon R. Cruz [Tue, 17 Nov 2015 17:43:01 +0000 (15:43 -0200)]
Fixing HNAS XML parser

HNAS XML parser does not handles situations where the user
could accidentally insert a blank space in the parameter value
breaking the driver in execution time. With this fix, an
error is raised in the driver setup.

Closes-bug: #1537758
Change-Id: If553647563638a5c9a09441ad2ec40ed13a0ece2

8 years agoMerge "Set LVM driver default overprovisioning ratio to 1.0"
Jenkins [Sat, 23 Jan 2016 05:57:28 +0000 (05:57 +0000)]
Merge "Set LVM driver default overprovisioning ratio to 1.0"

8 years agoMerge "Fix xtremio slow unit tests"
Jenkins [Sat, 23 Jan 2016 05:23:12 +0000 (05:23 +0000)]
Merge "Fix xtremio slow unit tests"

8 years agoMerge "Adding action to policy.json"
Jenkins [Sat, 23 Jan 2016 04:57:09 +0000 (04:57 +0000)]
Merge "Adding action to policy.json"

8 years agoIBM XIV/DS8K: Implements Replication V2
jiamin [Wed, 20 Jan 2016 09:24:41 +0000 (02:24 -0700)]
IBM XIV/DS8K: Implements Replication V2

This patch implements cinder Replication version 2 as proposed in
https://blueprints.launchpad.net/cinder/+spec/replication-v2

the changes are:
1. the ability to enable replication on the specified volume
2. the ability to disable replication on the specified volume.
3. the ability to return the list of replication targets for a volume
4. the ability to force failover to a secondary replication target.

DocImpact
Implements: blueprint ibm-xiv-ds8k-replication-v2
Change-Id: I04d1db17762fe72add2ab34193946daeca2f88e6

8 years agoMerge "DRBD: Rename "dres" to avoid confusion with "res""
Jenkins [Sat, 23 Jan 2016 01:40:45 +0000 (01:40 +0000)]
Merge "DRBD: Rename "dres" to avoid confusion with "res""

8 years agoMerge "Tegile tests: Change volume size to int"
Jenkins [Sat, 23 Jan 2016 01:07:47 +0000 (01:07 +0000)]
Merge "Tegile tests: Change volume size to int"

8 years agoAdds friendly zone name support
Angela Smith [Mon, 9 Nov 2015 18:14:35 +0000 (10:14 -0800)]
Adds friendly zone name support

Added user friendly names for zones to include host and storage
names along with ids to easily identify the host and storage port
details.

This is done by extracting the host and storage name from connection
info object in the zone manager. The host and storage names are passed
to the zone drivers to form a friendly name. The method signature has
been changed which accepts host and storage name, with default as None.

Also added test cases to test this support. Changes have been made to
zone manager test code to accommodate the change in signature of some
methods.

Moved get_friendly_zone_name method to utils.py so that it can be used
by both cisco and brocade drivers

Changed cisco driver to accommodate host_name and storage_system
parameters in add/delete connection.

Implements: blueprint brocade-zone-driver-friendly-zone-names

Change-Id: I350493b96901675a1b8910d6104f31c7d677ebda

8 years agoMerge "Huawei: Refactor driver for the second time"
Jenkins [Fri, 22 Jan 2016 22:53:19 +0000 (22:53 +0000)]
Merge "Huawei: Refactor driver for the second time"

8 years agoLeftHand: Implement v2 replication (unmanaged)
Alex O'Rourke [Mon, 23 Nov 2015 18:43:13 +0000 (10:43 -0800)]
LeftHand: Implement v2 replication (unmanaged)

This patch implements the unmanaged side of v2 replication in the HPE
LeftHand driver.

With unmanaged replication, the original driver instance will handle
all provisioning requests even after a failover.

cinder.conf should have the replication config group:

[lefthandrep]
hpelefthand_api_url = https://10.10.10.10:8081/lhos
hpelefthand_username = user
hpelefthand_password = pass
hpelefthand_clustername = vsa-12-5-mgmt1-vip
volume_backend_name = lefthandrep
volume_driver = cinder.volume.drivers.hpe.hpe_lefthand_iscsi.\
                HPELeftHandISCSIDriver
replication_device = target_device_id:lh-id,
                     hpelefthand_api_url:https://11.11.11.11:8081/lhos,
                     hpelefthand_username:user2,
                     hpelefthand_password:pass2,
                     hpelefthand_clustername:vsa-12-5-mgmt2-vip

Change-Id: I3c489e986648eee16b3bf5a19799a4ea0c0240b0
Implements: blueprint hp-lefthand-v2-replication
DocImpact

8 years agoEMC VMAX - VMAX driver failing to remove zones
Helen Walsh [Fri, 13 Nov 2015 00:42:49 +0000 (00:42 +0000)]
EMC VMAX - VMAX driver failing to remove zones

The population of the target_wwns and init_targ_map
should occur before the terminate_connection
and not after.

Closes-Bug: #1501938
Change-Id: I3a896a1fcdfd9c09a4c8fa5a1f7fb7253ff36715

8 years agoTests: Strengthen assertFalse assertions
Eric Harney [Mon, 4 Jan 2016 19:35:29 +0000 (14:35 -0500)]
Tests: Strengthen assertFalse assertions

These are all cases where we test with assertFalse,
but the call returns something more specific than False
which we should be checking for, such as None or [].

Test for the specific expected return value rather than
anything which will pass assertFalse.

Change-Id: I20cf89ba23e41f5a67bbf70b2b36fb9fecdd44c4

8 years agoMerge "Return BadRequest for invalid Unicode names"
Jenkins [Fri, 22 Jan 2016 13:23:46 +0000 (13:23 +0000)]
Merge "Return BadRequest for invalid Unicode names"

8 years agoFix laggard cisco FC zone client unit tests
Tom Barron [Thu, 21 Jan 2016 03:44:48 +0000 (22:44 -0500)]
Fix laggard cisco FC zone client unit tests

The test_cisco_fc_zone_client_cli.py unit module tests methods
decorated by utils.retry, which does retries with exponential
backoffs, without mocking out time.sleep().  One test in this
suite takes about 10% of the total time to run all cinder unit
tests.

This commit mocks time.sleep() in two critical tests in this
module, yielding a 30x speedup in run-time for the module.

Closes-Bug: #1536457

Change-Id: I3a686b760e2049a1f0ae4f8ee5ccbb4fa974aa1f

8 years agoFix xtremio slow unit tests
Tom Barron [Thu, 21 Jan 2016 20:53:03 +0000 (15:53 -0500)]
Fix xtremio slow unit tests

This commit mocks out time.sleep() in the test_retry_request()
method of test_emc_xtremio.EMCXIODriverTestCase.

As documented in the accompanying bug, this yields about a 6X
speedup for this unit test suite.

Change-Id: I86647dce1fe8a6e8281ee3617fbc5e5c1332404d
Closes-Bug: #1536782

8 years agoFix sluggish rbd unit tests
Tom Barron [Thu, 21 Jan 2016 16:56:14 +0000 (11:56 -0500)]
Fix sluggish rbd unit tests

The rbd_test.py module tests methods decorated by utils.retry,
which does retries with exponential backoffs, without mocking out
time.sleep().

This commit mocks time.sleep(), yielding a 3x speedup, as documented
in the accompanying bug.

Closes-Bug: #1536717

Change-Id: I414629f09f397e44d3a5be794ef83658a4c1eec0

8 years agoFix torpid coordinator unit tests
Tom Barron [Thu, 21 Jan 2016 18:17:59 +0000 (13:17 -0500)]
Fix torpid coordinator unit tests

The test_coordination.py unit module tests a _reconnect() method
which does a randomly seeded exponential retry backoff.  This
retry/backoff mechanism introduces needless delay in unit test
runs.

This commit mocks out random.uniform, improving run time by about
a factor of nine, as documented in the accompanying bug.

Closes-Bug: #1536750

Change-Id: I83fafba17be99cbe972dfb60fe87dac6dc3756cf

8 years agoMerge "EMC VMAX - Incorrect SG selected on an VMAX3 attach"
Jenkins [Fri, 22 Jan 2016 11:19:40 +0000 (11:19 +0000)]
Merge "EMC VMAX - Incorrect SG selected on an VMAX3 attach"

8 years agoMerge "Replace assertEqual(*, None) with assertIsNone in tests"
Jenkins [Fri, 22 Jan 2016 11:19:14 +0000 (11:19 +0000)]
Merge "Replace assertEqual(*, None) with assertIsNone in tests"