You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cloudstack.apache.org by "Nitin Mehta (JIRA)" <ji...@apache.org> on 2014/09/02 22:41:21 UTC

[jira] [Updated] (CLOUDSTACK-5997) Template state changes side affects

     [ https://issues.apache.org/jira/browse/CLOUDSTACK-5997?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Nitin Mehta updated CLOUDSTACK-5997:
------------------------------------
    Description: 
Template state change functionality.
A state has been introduced for vm_template. It reflects the user action for making template active/inactive for further use. 
When the template is marked inactive it becomes unusable for the entire cloud. 
If the user wants to make it as inactive for a particular zone, template_zone_ref would be accordingly reflected.
Admin listing should still be able to see the inactive templates.
The intent of the removed flag is to capture the system state meaning whether it has been physically removed from the cloud. 
The garbage collection thread checks the inactive state of the template and deletes it physically from sec. storage when no vm is referencing this template anymore. It also deletes it from PS.
This is when the removed flag is set in the vm_template table. At the moment this functionality doesn't exist in CS so the removed flag is never set as of now.
Things that need to be fixed
Deleting the template by user for a particular zone should mark the removed flag in template zone ref only. It should mark the template as inactive if its there is no other zone carrying it.
Deleting the template without any zone should mark it as inactive right away. 
Removed flag is not set and there shouldn't be any code setting it at the moment (Delete template shouldn't mark the removed flag.)
Start showing the state in the api. Regular users should see only active templates but admins should be able to see active/inactive templates
Template Sync. Should start using active/inactive state than the removed flag.
Show removed functionality introduced for CPBM would be fixed automatically when admin sees the inactive state - 
Any template code referencing the removed flag from vm_template should use the active/inactive flag.

> Template state changes side affects
> -----------------------------------
>
>                 Key: CLOUDSTACK-5997
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-5997
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>            Reporter: Nitin Mehta
>            Assignee: Nitin Mehta
>
> Template state change functionality.
> A state has been introduced for vm_template. It reflects the user action for making template active/inactive for further use. 
> When the template is marked inactive it becomes unusable for the entire cloud. 
> If the user wants to make it as inactive for a particular zone, template_zone_ref would be accordingly reflected.
> Admin listing should still be able to see the inactive templates.
> The intent of the removed flag is to capture the system state meaning whether it has been physically removed from the cloud. 
> The garbage collection thread checks the inactive state of the template and deletes it physically from sec. storage when no vm is referencing this template anymore. It also deletes it from PS.
> This is when the removed flag is set in the vm_template table. At the moment this functionality doesn't exist in CS so the removed flag is never set as of now.
> Things that need to be fixed
> Deleting the template by user for a particular zone should mark the removed flag in template zone ref only. It should mark the template as inactive if its there is no other zone carrying it.
> Deleting the template without any zone should mark it as inactive right away. 
> Removed flag is not set and there shouldn't be any code setting it at the moment (Delete template shouldn't mark the removed flag.)
> Start showing the state in the api. Regular users should see only active templates but admins should be able to see active/inactive templates
> Template Sync. Should start using active/inactive state than the removed flag.
> Show removed functionality introduced for CPBM would be fixed automatically when admin sees the inactive state - 
> Any template code referencing the removed flag from vm_template should use the active/inactive flag.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)