5001 Commits

Author SHA1 Message Date
Zuul
3effe78ba9 Merge "[NetApp] Fix share shrink error status" 2020-04-23 03:35:11 +00:00
Zuul
98dc72c72a Merge "fix bug in consume from share" 2020-04-23 01:32:16 +00:00
danielarthurt
c169902d41 [NetApp] Fix share shrink error status
This patch fixes the error raised by NetApp driver when the user try
to shrink a share to a size smaller than the current used space. Now
the driver raises "shrinking_possible_data_loss" instead of
"shrinking_error".

Change-Id: I01a549a0e299ae0d0d9b603a9d0797f16f4b68b3
Closes-Bug: #1858328
2020-04-22 15:50:11 +00:00
Zuul
22c2db599d Merge "fix bug in quota checking" 2020-04-22 12:20:52 +00:00
Zuul
9555e181f9 Merge "Use unittest.mock instead of third party lib" 2020-04-22 02:36:51 +00:00
zhangqing
7800539682 fix bug in quota checking
When project quota set unlimited(-1), and user in the
project is limited to a value.Then project quota must
smaller than project usage when checking quotas, which
means the value 'overs' is not None.
In this case, even though the user not over the quota,
but they can not create share

Closes-bug: #1872872

Change-Id: Id9e2bcb5d30d2b81b0723dd296b537ac7d4519f2
2020-04-22 09:52:02 +08:00
Goutham Pacha Ravi
ddb87233b3 [doc] Annotate max api microversion in Ussuri
Change-Id: Ied407002baf7d22691e28fccd00b31052d1d7afa
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-21 09:42:46 -07:00
Zuul
8949b6e92e Merge "VNX/PowerMax: Fix export locations" 2020-04-21 07:22:07 +00:00
zhangqing
4b471012de fix bug in consume from share
update provisioned_capacity_gb and allocated_capacity_gb

Closes-bug: #1872873
Change-Id: Ic239abafcb68063f3a6b007487141e5bb8315e0d
2020-04-20 15:56:51 +08:00
Zuul
301789f9be Merge "[cycle-goals] Add PTL and contributor quickstart" 2020-04-19 12:32:55 +00:00
Goutham Pacha Ravi
cf83f96200 [cycle-goals] Add PTL and contributor quickstart
These documents borrow from the cinder, nova and
ironic guides put together painstakingly by
numerous developers.

Change-Id: Ida3480fd1b9cab8eeb9ad002cce7200d89e01cb6
Story: #2007236
Task: #38535
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-18 22:29:50 +00:00
Goutham Pacha Ravi
598223985a Use unittest.mock instead of third party lib
mock was adopted into standard python
in version 3.3 [1]. Since manila no longer
supports python2.7, we can use the inbuilt
mock package rather than the third party
lib.

Fix some issues with imports that weren't
following our import conventions of grouping
imports [3]

Add a hacking test to ensure we don't regress
on this.

[1] https://docs.python.org/3/library/unittest.mock.html
[2] http://lists.openstack.org/pipermail/openstack-discuss/2020-March/013281.html
[3] https://docs.openstack.org/hacking/latest/user/hacking.html#imports

Co-Authored-By: Sean McGinnis <sean.mcginnis@gmail.com>
Change-Id: If857a49fbf526983e712282a25d7e8bef5093533
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-17 16:24:27 -07:00
zhangqing
879f2081c6 fix bug in tox py test
when running tox py36/37/38 test, it failed with error
MismatchError, reference in cinder [1].

[1] https://review.opendev.org/#/c/720008/
Closes-bug: #1872919

Change-Id: Ib76c8df7a435ba72cd0cffd7081d455fff02be0f
2020-04-16 15:16:05 +08:00
Zuul
9634bfa733 Merge "Fix invalid assert statement" 2020-04-15 05:17:49 +00:00
zhufl
c55589605c Fix invalid assert statement
This is to fix the following assert statements:
* asser_called_once_with, which should be assert_called_once_with
* asser_called_once, which should be assert_called_once

Change-Id: I0025b06d6b10249b118a46e67d8ca6ba56d4befd
2020-04-15 09:03:38 +08:00
Zuul
a1a89ab9a3 Merge "Delete type access list when deleting types" 2020-04-14 22:43:18 +00:00
Zuul
57d9880b74 Merge "Prevent share type deletion if linked to group types" 2020-04-14 19:01:02 +00:00
Zuul
10d5cbf639 Merge "Enable the use scheduler creating share from snapshot flag" 2020-04-14 19:01:00 +00:00
Zuul
a59987284b Merge "[NetApp] Fix vserver peer creation with same vserver" 2020-04-14 13:50:46 +00:00
Ryan Liang
9348766635 VNX/PowerMax: Fix export locations
It fixes the export locations returned by `create_share` and
`create_share_from_snapshot`. The export locations should be a list of
dict like: `[{'path': <original_location>}]`.

Change-Id: Ic97fa34455054aeda10608486edf120a9dc3d9f3
Closes-bug: #1871999
2020-04-14 12:14:59 +01:00
Douglas Viroel
0d949ac485 [NetApp] Fix vserver peer creation with same vserver
The NetApp cDOT driver is now fixed to ignore vserver peering
when creating and promoting shares replicas within the same
vserver.

Closes-Bug: #1872243
Change-Id: I0b82c15aec7862ee3630330805ac3ac177aae127
2020-04-13 16:31:23 -03:00
silvacarloss
2a4a63effe Fix docs duplicated autoclass definition
Fixed an issue in the contributor reference. The share replicas
documentation has two references to the same driver interface and
it caused a problem while generating docs, since none of them was
tagged with ``:noindex:``.

Change-Id: I9db0f2c07a8178895490fbcab9bfd9dcd2ccf823
Closes-Bug: #1872479
2020-04-13 16:10:04 +00:00
Zuul
2f833e14a0 Merge "[CI] Stop gating with manila-tempest-minimal-dsvm-lvm" 2020-04-11 02:56:31 +00:00
Goutham Pacha Ravi
14d081acf6 [CI] Stop gating with manila-tempest-minimal-dsvm-lvm
The job manila-tempest-minimal-dsvm-lvm is functionally
identical to manila-tempest-minimal-dsvm-lvm-ipv6-only.
Semantically, the only difference being that the service
host, and in turn the endpoint base for manila, and the
communication address for rabbitmq, mysql and other infra
services.

manila-tempest-minimal-dsvm-lvm-ipv6-only
has MANILA_SERVICE_HOST set to an IPv6 address,
for example:
MANILA_SERVICE_HOST='[::1]'
MANILA_ENDPOINT_BASE='http://[::1]:8786'

manila-tempest-minimal-dsvm-lvm has MANILA_SERVICE_HOST
set to an IPv4 address, for example:
MANILA_SERVICE_HOST='23.253.236.222'
MANILA_ENDPOINT_BASE='http://23.253.236.222:8786'

So lets drop the job enforcing IPv4 service host since
we have coverage for that scenario in other jobs that
we're running, including the voting
manila-tempest-minimal-dsvm-dummy job.

I'd like to backport this change to stable/train
during which this job was duplicated to cover the scenario
of doing "ipv6-only" service host testing [1]

[1] https://review.opendev.org/#/c/682716/

Change-Id: I51dc25889c1d1fb361f0be6f8c0aa47ca64c9aaa
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-10 13:21:15 -07:00
Zuul
ea90fd17b8 Merge "Remove experimental flag from share groups feature" 2020-04-10 10:36:56 +00:00
Zuul
c23797fe0f Merge "[ZFSonLinux] Create share from snapshot in different backends" 2020-04-10 09:03:38 +00:00
Douglas Viroel
63867a3ba9 [NetApp] Improve create share from snapshot functionality
This patch improves the operation of creating share from snapshot
to accept new destinations that can be different pools or
back ends.

Change-Id: Id3b3d5860d6325f368cbebfe7f97c98d64554d72
2020-04-09 18:22:35 -03:00
andrebeltrami
8f8ddfd670 [ZFSonLinux] Create share from snapshot in different backends
This patch improves the operation of create share from snapshot
to support different backends/hosts for the zfsonlinux driver

Partially-implements: bp create-share-from-snapshot-in-another-pool-or-backend

Depends-On: Iab13a0961eb4a387a502246e5d4b79bc9046e04b

Change-Id: I124803734c81d3630c5147f5f3bb75724489c929
2020-04-09 21:16:06 +00:00
silvacarloss
3e51ea34e3 Remove experimental flag from share groups feature
This patch updates the share groups APIs to be no longer considered
as experimental. It is done by removing the experimental flag from
the share groups, share group snapshots, share group extra specs
and share group types requests.

DocImpact
Partially-Implements: bp graduate-share-groups-feature
Change-Id: I080683541d527657f01008d43529fc53c19a09cd
2020-04-09 21:13:54 +00:00
Zuul
ba57e90d45 Merge "Create share from snapshot in another pool or backend" 2020-04-09 21:10:13 +00:00
Douglas Viroel
6c47b193b0 Create share from snapshot in another pool or backend
This patch enables the creation of a share from snapshot
specifying another pool or backend. In the scheduler, a
new filter and weigher were implemented in order to consider
this operation if the backend supports it. Also, a new
field called 'progress' was added in the share and share
instance. The 'progress' field indicates the status
of the operation create share from snapshot (in percentage).
Finally, a new periodic task was added in order to constantly
check the share status.

Partially-implements: bp create-share-from-snapshot-in-another-pool-or-backend

DOCImpact
Change-Id: Iab13a0961eb4a387a502246e5d4b79bc9046e04b
Co-authored-by: carloss <ces.eduardo98@gmail.com>
Co-authored-by: dviroel <viroel@gmail.com>
2020-04-09 11:15:22 -03:00
Zuul
64af75d72a Merge "[Unity] Manage/unmanage share server/share/snap" 2020-04-09 05:32:21 +00:00
dingd
252a7e8118 [Unity] Manage/unmanage share server/share/snap
1. Try parse share_backend_id from export path in case
it is managed share.

2. Try to take snapshot id from 'provider_location' in case
this is managed snapshot

3. Try to get share server name from property 'identifier'
first in case this is managed share server

4. Add property 'provider_location' when creating snapshot

Implements: blueprint emc-unity-manage-unmange

Change-Id: I676475d0500ecce31a1a863926accec8585ac83a
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-08 16:02:12 -07:00
Zuul
5eaa9e6046 Merge "Remove provisioned calculation on non thin provision backends" 2020-04-08 08:12:22 +00:00
Zuul
3fb8c5b7c4 Merge "Add new quota for share replicas" 2020-04-08 02:05:53 +00:00
Jose Castro Leon
2c30fed486 Remove provisioned calculation on non thin provision backends
On those backends, there is no need to calculate provisioned_capacity_gb
as it is not used during the scheduling. This calculation was not
scaling properly on big environments as it implies many database
queries.

Closes-Bug: #1869712

Change-Id: Icb8947991723a2a1cc334a72276a35cf50fc1b7d
2020-04-07 21:09:40 +02:00
Zuul
7c6bd92b66 Merge "[NetApp] Fix driver to honor standard extra specs" 2020-04-07 06:10:18 +00:00
Goutham Pacha Ravi
5f80a24ff2 Delete type access list when deleting types
Currently we're in a foobar situation with two database
models ShareTypeProjects and ShareGroupTypeProjects
where we keep stuff around even when the concerned
ShareType or ShareGroupType objects are deleted.

So, delete type access rules when types are being deleted.

Change-Id: Id135a96f2d1b7306156bab0ddedcb1b838a74f0a
Closes-Bug: #1870751
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-06 08:52:36 -07:00
silvacarloss
dceced6d6e Add new quota for share replicas
This patch adds new quotas for share replicas and replica sizes.
This quotas can be related to either tenants and users or tenants
and share types. Now, when creating a share replica, manila will
check if there are resources available for that specific request.

Partially-Implements: bp limit-share-replicas-per-share
Change-Id: I8ba7bc6f167c28d6c169b2187d0e1bda7cad3f69
2020-04-06 13:17:30 +00:00
Goutham Pacha Ravi
470bab7c71 Prevent share type deletion if linked to group types
Share types can be associated with share group
types. This relationship needs to be dropped in
case share types are to be deleted, or we'll be
leaving behind dead references in the database.
Share groups cannot exist without share group
types, and hence we don't need to check on existing
groups when deleting share types; checking for
existing group types will suffice.

Change-Id: Id86a93f1923a493cefe73e2d90d5094005b42ae4
Closes-Bug: #1699836
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-05 16:32:52 -07:00
Zuul
1edd0c39a6 Merge "Support query user message by timestamp" 2020-04-03 18:11:35 +00:00
Zuul
778a5dd979 Merge "Revert "Remove provisioned calculation on non thin provision backends"" 2020-04-03 14:37:54 +00:00
Zuul
15fb588d0a Merge "Hacking: Fix W605" 2020-04-03 05:39:12 +00:00
Zuul
0b86718873 Merge "Hacking: Fix E731" 2020-04-03 03:34:12 +00:00
Zuul
e182eccb5e Merge "Increase MANILA_SERVICE_VM_FLAVOR_DISK" 2020-04-03 00:41:16 +00:00
Tom Barron
c0ee00f2c7 Increase MANILA_SERVICE_VM_FLAVOR_DISK
The manila service image was recently rebuilt and is
now bigger than 2 Gibibytes so increase it to 3, which
should last us for a while.

Closes-bug: #1870412

Change-Id: Ia03e48a3f0ff352b94a0224f76f278ef45acad93
2020-04-02 21:03:27 +00:00
haixin
35e82746e8 Support query user message by timestamp
Add support for querying user messages by specifying a timestamp, which
will be compared to the created_at field, and manila will return all the
messages matching to the time condition.

Partially-Implements: blueprint query-user-message-by-timestamp

Change-Id: I3d94bac4304c236f275abe7ce31432b0e2384247
2020-04-02 11:07:39 +08:00
Goutham Pacha Ravi
4d53f3ec41 Revert "Remove provisioned calculation on non thin provision backends"
This fix doesn't fully address the issue given that share backends
are allowed to use a list of capabilities and reporting thin_provisioning as
[False] will still allow the calculation of provisioned_capacity_gb.

Bug #1869712 will be fixed in a follow up patch.

This reverts commit cd9292b931a0f74079512cd43652129a9c595ee8.

Change-Id: I922f161980e8a1ef7cf111b1e30c02991073d6e5
2020-04-01 17:33:45 +00:00
Andreas Jaeger
3fdd9983e0 Hacking: Fix W605
Fix:
W605 invalid escape sequence

This is the final change I plan for hacking, the remaining problems
need further investigation by manila team and decision whether and how
to solve them.

Change-Id: I73d73e044eaaf412bf7ace358a3f07c8d269d6cf
2020-04-01 14:38:14 +02:00
Andreas Jaeger
27808af118 Hacking: Fix E731
Fix:
E731 do not assign a lambda expression, use a def

I just marked the lambdas with noqa.

Fix also other problems found by hacking in files changed.

Change-Id: I4e47670f5a96e61fba617e4cb9478958f7089711
2020-04-01 14:11:10 +02:00