To enhance security and prevent unintended removal of critical resources, we've introduced deletion protection for Organizations, Tenants, Workspaces, and Groups. This documentation provides an overview of the features and how to manage them.
deletionProtectionEnabledField: This is a new attribute added to resources, namely Organizations, Tenants, Workspaces, and Config Groups (Gateway Groups, Traffic Group, Security Group and Istio Internal Group). By default, this field is set to
disabled, meaning resources can be deleted unless this protection is explicitly enabled.
To enable deletion protection, set the
truein the resource's YAML file. For example, to enable deletion protection on a Tenant, add the following to the YAML file:
displayName: Tenant Name
Hierarchical Resource Protection: Protection isn’t just on a single-resource level. If a resource is protected or if any of its child resources have deletion protection enabled, the parent resource cannot be deleted. This ensures that inadvertent deletions don't affect dependent or related resources.
To understand TSB Hierarchical Resource, please refer to TSB Resource Model.
Modifying Deletion Protection: Before a protected resource can be deleted, the
deletionProtectionEnabledflag must be cleared or set to
disabled. This adds an additional layer of confirmation, ensuring that resources aren't deleted accidentally.
-forceFlag on tctl delete Command: For users who wish to bypass the standard deletion protection measures, the
--forceflag has been introduced. When using the
tctl deletecommand with the
--forceflag, the resource will be deleted without the need to manually clear the
deletionProtectionEnabledproperty first. Caution is advised when using this flag as it overrides the built-in safety measures.
Guidelines for Using Deletion Protection:
- Enable Protection Where Necessary: While the default setting is
disabled, it's recommended to enable deletion protection on critical resources to prevent unintentional loss.
- Regularly Review Protected Resources: Periodically review and ensure that the correct resources are protected. This prevents any hindrance when intentional deletions are required.
--forceFlag with Caution: The force delete option is powerful and can lead to unintentional data loss. Always confirm the details of the resource before proceeding with a force delete.
The deletion protection feature is here to aid in preserving the integrity and structure of your resources. Use it wisely to ensure that your data and configurations remain safe and intact.