<div dir="ltr"><div class="gmail_default" style="font-family:monospace,monospace"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Dec 8, 2015 at 9:10 PM, Li, Xiaoyan <span dir="ltr"><<a href="mailto:xiaoyan.li@intel.com" target="_blank">xiaoyan.li@intel.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi all,<br>
<br>
Currently when deleting a volume, it checks whether there are snapshots created from it. If yes deletion is prohibited.  But it allows to extend  the volume, no check whether there are snapshots from it.<br></blockquote><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​Correct​</div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
The two behaviors in Cinder are not consistent from my viewpoint.<br></blockquote><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​Well, your snapshot was taken at a point in time; and if you do a create from snapshot the whole point is you want what you HAD when the snapshot command was issued and NOT what happened afterwards.  So in my opinion this is not inconsistent at all.</div></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​</div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
In backend storage, their behaviors are same.<br></blockquote><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​Which backend storage are you referring to in this case?</div></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​</div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
For full snapshot, if still in copying progress, both extend and deletion are not allowed. If snapshot copying finishes, both extend and deletion are allowed.<br>
For incremental snapshot, both extend and deletion are not allowed.<br></blockquote><div><br></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​So your particular backend has "different/specific" rules/requirements around snapshots.  That's pretty common, I don't suppose theres any way to hack around this internally?  In other words do things on your backend like clones as snaps etc to make up for the differences in behavior?​</div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
As a result, this raises two concerns here:<br>
1. Let such operations behavior same in Cinder.<br>
2. I prefer to let storage driver decide the dependencies, not in the general core codes.<br></blockquote><div><br></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">​I have and always will strongly disagree with this approach and your proposal.  Sadly we've already started to allow more and more vendor drivers just "do their own thing" and implement their own special API methods.  This is in my opinion a horrible path and defeats the entire purpose of have a Cinder abstraction layer.</div></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline"><br></div></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">This will make it impossible to have compatibility between clouds for those that care about it, it will make it impossible for operators/deployers to understand exactly what they can and should expect in terms of the usage of their cloud.  Finally, it will also mean that not OpenStack API functionality is COMPLETELY dependent on backend device.  I know people are sick of hearing me say this, so I'll keep it short and say it one more time:</div></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline">"Compatibility in the API matters and should always be our priority"</div></div><div><div class="gmail_default" style="font-family:monospace,monospace;display:inline"><br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Meanwhile, if we let driver to decide the dependencies, the following changes need to do in Cinder:<br>
1. When creating a snapshot from volume, it needs copy all metadata of volume to snapshot. Currently it doesn't.<br>
Any other potential issues please let me know.<br>
<br>
Any input will be appreciated.<br>
<br>
Best wishes<br>
Lisa<br>
<br>
<br>
__________________________________________________________________________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" target="_blank">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
</blockquote></div><br></div></div>