create_share_from_snapshot does not work as expected from first attempt

Bug #1685657 reported by Rodrigo Barbieri
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
manila-ui
Fix Released
High
Valeriy Ponomaryov

Bug Description

Creating a new share from snapshot does not detect the source snapshot, thus the snapshot is empty (like a brand new share) in case we send request setting all required fields from first time. In case we fail first attempt and are forced to update required fields then it works as expected.

Steps to reproduce:

1. Create a share X, add access rule, mount and add some files
2. Create a snapshot Y of share X
3. Proceed to create a share Z from snapshot Y (from snapshots screen "=> create share" in snapshot Y's row)
3.1. Fill all mandatory fields of the "Create Share" form before clicking "OK". Failing to do so and causing the form to reload will avoid the problem.
4. Add access rule to share Z, mount and check if files are there <== files are not there

Revision history for this message
Valeriy Ponomaryov (vponomaryov) wrote :

"Steps to reproduce" show that we have share with specified snapshot as a source.
If you have problems with some backends losing files, it is not Manila UI problem.

Changed in manila-ui:
status: New → Invalid
Revision history for this message
Rodrigo Barbieri (rodrigo-barbieri2010) wrote :

Valeriy, I updated the steps with more detail.

description: updated
summary: - create_share_from_snapshot does not work
+ create_share_from_snapshot does not work as expected from first attempt
description: updated
Changed in manila-ui:
status: Invalid → Triaged
importance: Undecided → High
Changed in manila-ui:
assignee: nobody → Valeriy Ponomaryov (vponomaryov)
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila-ui (master)

Fix proposed to branch: master
Review: https://review.openstack.org/460248

tags: added: ocata-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila-ui (master)

Reviewed: https://review.openstack.org/460248
Committed: https://git.openstack.org/cgit/openstack/manila-ui/commit/?id=c458dff54c4f162c4a3ce7a743fc70d5595ede6a
Submitter: Jenkins
Branch: master

commit c458dff54c4f162c4a3ce7a743fc70d5595ede6a
Author: Valeriy Ponomaryov <email address hidden>
Date: Wed Apr 26 20:34:25 2017 +0300

    Fix share creation from snapshot

    For the moment if we create share from snapshot from first attempt
    we get share created from scratch, not from snapshot. This bug appered
    after merge of [1] to manila and usage of 2.6+ microversion in Manila UI.
    The reason why [1] had influence is in changed share view that became
    incompatible with 'choices' in UI that depend on share type names.
    So, start using correct field 'share_type_name', that will set default
    value for share type omitting the need to set it manually all the time,
    it also will trigger correct snapshot ID selection for request.
    Also, fix logic for second+ attempt, where we were using different set
    of data after failed attempt to submit request.

    [1] I082bdac82c981adf733c709472ce1b9e26d5650b

    Change-Id: I4b5a04ed16d8e579ad816e84ad907ddd97e13ac1
    Closes-Bug: #1685657

Changed in manila-ui:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila-ui (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/460710

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila-ui (stable/ocata)

Reviewed: https://review.openstack.org/460710
Committed: https://git.openstack.org/cgit/openstack/manila-ui/commit/?id=4e806e12cb7405052388e4447c6c0b17480f3a20
Submitter: Jenkins
Branch: stable/ocata

commit 4e806e12cb7405052388e4447c6c0b17480f3a20
Author: Valeriy Ponomaryov <email address hidden>
Date: Wed Apr 26 20:34:25 2017 +0300

    Fix share creation from snapshot

    For the moment if we create share from snapshot from first attempt
    we get share created from scratch, not from snapshot. This bug appered
    after merge of [1] to manila and usage of 2.6+ microversion in Manila UI.
    The reason why [1] had influence is in changed share view that became
    incompatible with 'choices' in UI that depend on share type names.
    So, start using correct field 'share_type_name', that will set default
    value for share type omitting the need to set it manually all the time,
    it also will trigger correct snapshot ID selection for request.
    Also, fix logic for second+ attempt, where we were using different set
    of data after failed attempt to submit request.

    [1] I082bdac82c981adf733c709472ce1b9e26d5650b

    Change-Id: I4b5a04ed16d8e579ad816e84ad907ddd97e13ac1
    Closes-Bug: #1685657
    (cherry picked from commit c458dff54c4f162c4a3ce7a743fc70d5595ede6a)

tags: added: in-stable-ocata
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila-ui 2.9.0

This issue was fixed in the openstack/manila-ui 2.9.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.