diff --git a/lower-constraints.txt b/lower-constraints.txt index 7486b72fbd..81fdb0fb0b 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -64,7 +64,7 @@ oslo.i18n==5.0.1 oslo.log==4.4.0 oslo.messaging==12.5.0 oslo.middleware==4.1.1 -oslo.policy==3.6.2 +oslo.policy==3.7.0 oslo.reports==2.2.0 oslo.rootwrap==6.2.0 oslo.serialization==4.0.1 diff --git a/manila/policies/availability_zone.py b/manila/policies/availability_zone.py index 70baf90c2a..2b8fcbd336 100644 --- a/manila/policies/availability_zone.py +++ b/manila/policies/availability_zone.py @@ -24,7 +24,9 @@ The availability zone API now supports system scope and default roles. deprecated_get_availability_zone = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -44,9 +46,7 @@ availability_zone_policies = [ 'path': '/availability-zone', }, ], - deprecated_rule=deprecated_get_availability_zone, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_get_availability_zone ), ] diff --git a/manila/policies/message.py b/manila/policies/message.py index db7dfafb5b..3db1c03faf 100644 --- a/manila/policies/message.py +++ b/manila/policies/message.py @@ -24,15 +24,21 @@ The messages API now supports system scope and default roles. deprecated_message_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_message_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_message_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -48,9 +54,7 @@ message_policies = [ 'path': '/messages/{message_id}' } ], - deprecated_rule=deprecated_message_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_message_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all', @@ -67,9 +71,7 @@ message_policies = [ 'path': '/messages?{query}' } ], - deprecated_rule=deprecated_message_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_message_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -82,9 +84,7 @@ message_policies = [ 'path': '/messages/{message_id}' } ], - deprecated_rule=deprecated_message_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_message_delete ), ] diff --git a/manila/policies/quota_class_set.py b/manila/policies/quota_class_set.py index fa30f4ae02..651e792268 100644 --- a/manila/policies/quota_class_set.py +++ b/manila/policies/quota_class_set.py @@ -24,11 +24,15 @@ The quota class API now supports system scope and default roles. deprecated_quota_class_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_quota_class_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -48,9 +52,7 @@ quota_class_set_policies = [ 'path': '/os-quota-class-sets/{class_name}' } ], - deprecated_rule=deprecated_quota_class_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_quota_class_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -67,9 +69,7 @@ quota_class_set_policies = [ 'path': '/os-quota-class-sets/{class_name}' } ], - deprecated_rule=deprecated_quota_class_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_quota_class_show ), ] diff --git a/manila/policies/quota_set.py b/manila/policies/quota_set.py index b8468c3876..d6fdfd1bb8 100644 --- a/manila/policies/quota_set.py +++ b/manila/policies/quota_set.py @@ -24,15 +24,21 @@ The quota API now supports system scope and default roles. deprecated_quota_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_quota_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_quota_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -65,9 +71,7 @@ quota_set_policies = [ 'path': '/os-quota-sets/{tenant_id}?user_id={user_id}' }, ], - deprecated_rule=deprecated_quota_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_quota_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -84,9 +88,7 @@ quota_set_policies = [ 'path': '/os-quota-sets/{tenant_id}/defaults' } ], - deprecated_rule=deprecated_quota_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_quota_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -117,9 +119,7 @@ quota_set_policies = [ 'path': '/os-quota-sets/{tenant_id}?user_id={user_id}' }, ], - deprecated_rule=deprecated_quota_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_quota_delete ), ] diff --git a/manila/policies/scheduler_stats.py b/manila/policies/scheduler_stats.py index fe48aa2021..93d17dcbaf 100644 --- a/manila/policies/scheduler_stats.py +++ b/manila/policies/scheduler_stats.py @@ -24,11 +24,15 @@ The storage pool statistics API now support system scope and default roles. deprecated_pool_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_pool_detail = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'detail', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -49,9 +53,7 @@ scheduler_stats_policies = [ 'path': '/scheduler-stats/pools?{query}' } ], - deprecated_rule=deprecated_pool_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_pool_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'detail', @@ -69,9 +71,7 @@ scheduler_stats_policies = [ 'path': '/scheduler-stats/pools/detail' } ], - deprecated_rule=deprecated_pool_detail, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_pool_detail ), ] diff --git a/manila/policies/security_service.py b/manila/policies/security_service.py index 5f39197ef9..7b3311fbaa 100644 --- a/manila/policies/security_service.py +++ b/manila/policies/security_service.py @@ -24,31 +24,45 @@ The security service API now supports system scope and default roles. deprecated_security_service_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_security_service_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_security_service_detail = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'detail', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_security_service_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_security_service_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_security_service_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_security_service_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all_security_services', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -64,9 +78,7 @@ security_service_policies = [ 'path': '/security-services' } ], - deprecated_rule=deprecated_security_service_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -79,9 +91,7 @@ security_service_policies = [ 'path': '/security-services/{security_service_id}' } ], - deprecated_rule=deprecated_security_service_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'detail', @@ -98,9 +108,7 @@ security_service_policies = [ 'path': '/security-services/detail' } ], - deprecated_rule=deprecated_security_service_detail, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_detail ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -117,9 +125,7 @@ security_service_policies = [ 'path': '/security-services?{query}' } ], - deprecated_rule=deprecated_security_service_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -132,9 +138,7 @@ security_service_policies = [ 'path': '/security-services/{security_service_id}', } ], - deprecated_rule=deprecated_security_service_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -147,9 +151,7 @@ security_service_policies = [ 'path': '/security-services/{security_service_id}' } ], - deprecated_rule=deprecated_security_service_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all_security_services', @@ -166,9 +168,7 @@ security_service_policies = [ 'path': '/security-services/detail?all_tenants=1' } ], - deprecated_rule=deprecated_security_service_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_security_service_get_all ), ] diff --git a/manila/policies/service.py b/manila/policies/service.py index 349d1fe594..cbd4c3fb05 100644 --- a/manila/policies/service.py +++ b/manila/policies/service.py @@ -24,11 +24,15 @@ The service API now supports system scope and default roles. deprecated_service_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_service_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -56,9 +60,7 @@ service_policies = [ 'path': '/services?{query}', } ], - deprecated_rule=deprecated_service_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_service_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -83,9 +85,7 @@ service_policies = [ 'path': '/services/enable', }, ], - deprecated_rule=deprecated_service_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_service_update ), ] diff --git a/manila/policies/share_access.py b/manila/policies/share_access.py index 622485cb9a..82921aaed7 100644 --- a/manila/policies/share_access.py +++ b/manila/policies/share_access.py @@ -27,11 +27,15 @@ The share access rule API now supports system scope and default roles. deprecated_access_rule_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_access_rule_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -47,9 +51,7 @@ share_access_rule_policies = [ 'path': '/share-access-rules/{share_access_id}' } ], - deprecated_rule=deprecated_access_rule_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_access_rule_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -63,9 +65,7 @@ share_access_rule_policies = [ '&key1=value1&key2=value2') } ], - deprecated_rule=deprecated_access_rule_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_access_rule_index ), ] diff --git a/manila/policies/share_access_metadata.py b/manila/policies/share_access_metadata.py index 18c18e8a7f..593fa34672 100644 --- a/manila/policies/share_access_metadata.py +++ b/manila/policies/share_access_metadata.py @@ -27,11 +27,15 @@ The share access metadata API now support system scope and default roles. deprecated_access_metadata_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_access_metadata_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -47,9 +51,7 @@ share_access_rule_metadata_policies = [ 'path': '/share-access-rules/{share_access_id}/metadata' } ], - deprecated_rule=deprecated_access_metadata_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_access_metadata_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -62,9 +64,7 @@ share_access_rule_metadata_policies = [ 'path': '/share-access-rules/{share_access_id}/metadata/{key}' } ], - deprecated_rule=deprecated_access_metadata_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_access_metadata_delete ), ] diff --git a/manila/policies/share_export_location.py b/manila/policies/share_export_location.py index df07147db9..ecbc33759c 100644 --- a/manila/policies/share_export_location.py +++ b/manila/policies/share_export_location.py @@ -24,11 +24,15 @@ The share export location API now support system scope and default roles. deprecated_export_location_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_export_location_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -44,9 +48,7 @@ share_export_location_policies = [ 'path': '/shares/{share_id}/export_locations', } ], - deprecated_rule=deprecated_export_location_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_export_location_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -60,9 +62,7 @@ share_export_location_policies = [ '{export_location_id}'), } ], - deprecated_rule=deprecated_export_location_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_export_location_show ), ] diff --git a/manila/policies/share_group.py b/manila/policies/share_group.py index 1acbacab7c..f4f7d70445 100644 --- a/manila/policies/share_group.py +++ b/manila/policies/share_group.py @@ -24,31 +24,45 @@ The share group API now supports system scope and default roles. deprecated_share_group_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_force_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'force_delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -64,9 +78,7 @@ share_group_policies = [ 'path': '/share-groups' } ], - deprecated_rule=deprecated_share_group_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get', @@ -79,9 +91,7 @@ share_group_policies = [ 'path': '/share-groups/{share_group_id}' } ], - deprecated_rule=deprecated_share_group_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all', @@ -106,9 +116,7 @@ share_group_policies = [ 'path': '/share-groups/detail?{query}' } ], - deprecated_rule=deprecated_share_group_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -121,9 +129,7 @@ share_group_policies = [ 'path': '/share-groups/{share_group_id}' } ], - deprecated_rule=deprecated_share_group_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -136,9 +142,7 @@ share_group_policies = [ 'path': '/share-groups/{share_group_id}' } ], - deprecated_rule=deprecated_share_group_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'force_delete', @@ -151,9 +155,7 @@ share_group_policies = [ 'path': '/share-groups/{share_group_id}/action' } ], - deprecated_rule=deprecated_share_group_force_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_force_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -166,9 +168,7 @@ share_group_policies = [ 'path': '/share-groups/{share_group_id}/action' } ], - deprecated_rule=deprecated_share_group_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_reset_status ), ] diff --git a/manila/policies/share_group_snapshot.py b/manila/policies/share_group_snapshot.py index c90080b4b3..7f1e7b6734 100644 --- a/manila/policies/share_group_snapshot.py +++ b/manila/policies/share_group_snapshot.py @@ -24,31 +24,45 @@ The share group snapshots API now supports system scope and default roles. deprecated_group_snapshot_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_snapshot_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_snapshot_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_snapshot_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_snapshot_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_snapshot_force_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'force_delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_snapshot_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -64,9 +78,7 @@ share_group_snapshot_policies = [ 'path': '/share-group-snapshots' } ], - deprecated_rule=deprecated_group_snapshot_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get', @@ -79,9 +91,7 @@ share_group_snapshot_policies = [ 'path': '/share-group-snapshots/{share_group_snapshot_id}' } ], - deprecated_rule=deprecated_group_snapshot_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all', @@ -106,9 +116,7 @@ share_group_snapshot_policies = [ 'path': '/share-group-snapshots/detail?{query}' } ], - deprecated_rule=deprecated_group_snapshot_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -121,9 +129,7 @@ share_group_snapshot_policies = [ 'path': '/share-group-snapshots/{share_group_snapshot_id}' } ], - deprecated_rule=deprecated_group_snapshot_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -136,9 +142,7 @@ share_group_snapshot_policies = [ 'path': '/share-group-snapshots/{share_group_snapshot_id}' } ], - deprecated_rule=deprecated_group_snapshot_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'force_delete', @@ -152,9 +156,7 @@ share_group_snapshot_policies = [ 'action' } ], - deprecated_rule=deprecated_group_snapshot_force_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_force_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -168,9 +170,7 @@ share_group_snapshot_policies = [ 'action' } ], - deprecated_rule=deprecated_group_snapshot_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_snapshot_reset_status ), ] diff --git a/manila/policies/share_group_type.py b/manila/policies/share_group_type.py index 451138c6d5..aa730e06de 100644 --- a/manila/policies/share_group_type.py +++ b/manila/policies/share_group_type.py @@ -24,35 +24,51 @@ The share group type API now supports system scope and default roles. deprecated_share_group_type_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_get_default = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'default', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_project_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'list_project_access', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_add_project = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'add_project_access', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_group_type_remove_project = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'remove_project_access', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -68,9 +84,7 @@ share_group_type_policies = [ 'path': '/share-group-types', } ], - deprecated_rule=deprecated_share_group_type_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -87,9 +101,7 @@ share_group_type_policies = [ 'path': '/share-group-types?is_public=all', } ], - deprecated_rule=deprecated_share_group_type_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -102,9 +114,7 @@ share_group_type_policies = [ 'path': '/share-group-types/{share_group_type_id}', } ], - deprecated_rule=deprecated_share_group_type_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'default', @@ -117,9 +127,7 @@ share_group_type_policies = [ 'path': '/share-group-types/default', } ], - deprecated_rule=deprecated_share_group_type_get_default, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_get_default ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -132,9 +140,7 @@ share_group_type_policies = [ 'path': '/share-group-types/{share_group_type_id}' } ], - deprecated_rule=deprecated_share_group_type_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'list_project_access', @@ -147,9 +153,7 @@ share_group_type_policies = [ 'path': '/share-group-types/{share_group_type_id}/access', } ], - deprecated_rule=deprecated_share_group_type_project_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_project_access ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'add_project_access', @@ -162,9 +166,7 @@ share_group_type_policies = [ 'path': '/share-group-types/{share_group_type_id}/action', } ], - deprecated_rule=deprecated_share_group_type_add_project, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_add_project ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'remove_project_access', @@ -177,9 +179,7 @@ share_group_type_policies = [ 'path': '/share-group-types/{share_group_type_id}/action', } ], - deprecated_rule=deprecated_share_group_type_remove_project, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_group_type_remove_project ), ] diff --git a/manila/policies/share_group_types_spec.py b/manila/policies/share_group_types_spec.py index 392b8204cf..f6b5693e55 100644 --- a/manila/policies/share_group_types_spec.py +++ b/manila/policies/share_group_types_spec.py @@ -24,23 +24,33 @@ The share group type specs API now support system scope and default roles. deprecated_group_type_spec_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_type_spec_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_type_spec_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_type_spec_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_group_type_spec_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -56,9 +66,7 @@ share_group_types_spec_policies = [ 'path': '/share-group-types/{share_group_type_id}/group-specs' } ], - deprecated_rule=deprecated_group_type_spec_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_type_spec_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -71,9 +79,7 @@ share_group_types_spec_policies = [ 'path': '/share-group-types/{share_group_type_id}/group-specs', } ], - deprecated_rule=deprecated_group_type_spec_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_type_spec_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -87,9 +93,7 @@ share_group_types_spec_policies = [ 'group-specs/{key}'), } ], - deprecated_rule=deprecated_group_type_spec_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_type_spec_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -103,9 +107,7 @@ share_group_types_spec_policies = [ '/group-specs/{key}'), } ], - deprecated_rule=deprecated_group_type_spec_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_type_spec_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -119,9 +121,7 @@ share_group_types_spec_policies = [ 'group-specs/{key}'), } ], - deprecated_rule=deprecated_group_type_spec_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_group_type_spec_delete ), ] diff --git a/manila/policies/share_instance.py b/manila/policies/share_instance.py index b5a3371094..1b18706a09 100644 --- a/manila/policies/share_instance.py +++ b/manila/policies/share_instance.py @@ -24,19 +24,27 @@ The share instances API now supports system scope and default roles. deprecated_share_instances_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_instance_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_instance_force_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'force_delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_instance_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -56,9 +64,7 @@ shares_policies = [ 'path': '/share_instances?{query}', } ], - deprecated_rule=deprecated_share_instances_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_instances_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -71,9 +77,7 @@ shares_policies = [ 'path': '/share_instances/{share_instance_id}' }, ], - deprecated_rule=deprecated_share_instance_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_instance_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'force_delete', @@ -86,9 +90,7 @@ shares_policies = [ 'path': '/share_instances/{share_instance_id}/action', } ], - deprecated_rule=deprecated_share_instance_force_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_instance_force_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -101,9 +103,7 @@ shares_policies = [ 'path': '/share_instances/{share_instance_id}/action', } ], - deprecated_rule=deprecated_share_instance_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_instance_reset_status ), ] diff --git a/manila/policies/share_instance_export_location.py b/manila/policies/share_instance_export_location.py index 3146d03e10..a72d74ee2d 100644 --- a/manila/policies/share_instance_export_location.py +++ b/manila/policies/share_instance_export_location.py @@ -28,11 +28,15 @@ roles. deprecated_instance_export_location_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_instance_export_location_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -49,9 +53,7 @@ share_export_location_policies = [ 'export_locations'), } ], - deprecated_rule=deprecated_instance_export_location_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_instance_export_location_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -65,9 +67,7 @@ share_export_location_policies = [ 'export_locations/{export_location_id}'), } ], - deprecated_rule=deprecated_instance_export_location_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_instance_export_location_show ), ] diff --git a/manila/policies/share_network.py b/manila/policies/share_network.py index 1d58fd1bf9..6d736acf8e 100644 --- a/manila/policies/share_network.py +++ b/manila/policies/share_network.py @@ -23,55 +23,81 @@ The share network API now support system scope and default roles. deprecated_share_network_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_detail = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'detail', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_add_security_service = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'add_security_service', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_remove_security_service = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'remove_security_service', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all_share_networks', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_add_security_service_check = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'add_security_service_check', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_update_security_service = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update_security_service', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_update_security_service_check = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update_security_service_check', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_network_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) share_network_policies = [ @@ -86,9 +112,7 @@ share_network_policies = [ 'path': '/share-networks' } ], - deprecated_rule=deprecated_share_network_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -101,9 +125,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}' } ], - deprecated_rule=deprecated_share_network_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -120,9 +142,7 @@ share_network_policies = [ 'path': '/share-networks?{query}' } ], - deprecated_rule=deprecated_share_network_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'detail', @@ -139,9 +159,7 @@ share_network_policies = [ 'path': '/share-networks/detail' }, ], - deprecated_rule=deprecated_share_network_detail, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_detail ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -154,9 +172,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}' } ], - deprecated_rule=deprecated_share_network_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -169,9 +185,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}' } ], - deprecated_rule=deprecated_share_network_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'add_security_service', @@ -184,9 +198,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}/action' } ], - deprecated_rule=deprecated_share_network_add_security_service, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_add_security_service ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'add_security_service_check', @@ -200,9 +212,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}/action' } ], - deprecated_rule=deprecated_share_network_add_security_service_check, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_add_security_service_check ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'remove_security_service', @@ -215,9 +225,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}/action' } ], - deprecated_rule=deprecated_share_network_remove_security_service, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_remove_security_service ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update_security_service', @@ -230,9 +238,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}/action' } ], - deprecated_rule=deprecated_share_network_update_security_service, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_update_security_service ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update_security_service_check', @@ -246,9 +252,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}/action' } ], - deprecated_rule=deprecated_share_network_update_security_service_check, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_update_security_service_check ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -261,9 +265,7 @@ share_network_policies = [ 'path': '/share-networks/{share_network_id}/action' } ], - deprecated_rule=deprecated_share_network_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_reset_status ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all_share_networks', @@ -280,9 +282,7 @@ share_network_policies = [ 'path': '/share-networks/detail?all_tenants=1' } ], - deprecated_rule=deprecated_share_network_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_network_get_all ), ] diff --git a/manila/policies/share_network_subnet.py b/manila/policies/share_network_subnet.py index 29cfdd954d..dac51d7e97 100644 --- a/manila/policies/share_network_subnet.py +++ b/manila/policies/share_network_subnet.py @@ -26,19 +26,27 @@ The share network subnet API now supports system scope and default roles. deprecated_subnet_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_subnet_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_subnet_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_subnet_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -54,9 +62,7 @@ share_network_subnet_policies = [ 'path': '/share-networks/{share_network_id}/subnets' } ], - deprecated_rule=deprecated_subnet_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_subnet_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -70,9 +76,7 @@ share_network_subnet_policies = [ '{share_network_subnet_id}' } ], - deprecated_rule=deprecated_subnet_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_subnet_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -86,9 +90,7 @@ share_network_subnet_policies = [ '{share_network_subnet_id}' } ], - deprecated_rule=deprecated_subnet_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_subnet_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -101,9 +103,7 @@ share_network_subnet_policies = [ 'path': '/share-networks/{share_network_id}/subnets' } ], - deprecated_rule=deprecated_subnet_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_subnet_index ), ] diff --git a/manila/policies/share_replica.py b/manila/policies/share_replica.py index 557579b785..63b56a06b2 100644 --- a/manila/policies/share_replica.py +++ b/manila/policies/share_replica.py @@ -24,39 +24,57 @@ The share replica API now supports system scope and default roles. deprecated_replica_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_force_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'force_delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_promote = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'promote', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_resync = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'resync', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_reset_state = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_replica_state', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -72,9 +90,7 @@ share_replica_policies = [ 'path': '/share-replicas', } ], - deprecated_rule=deprecated_replica_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all', @@ -95,9 +111,7 @@ share_replica_policies = [ 'path': '/share-replicas/detail?share_id={share_id}', } ], - deprecated_rule=deprecated_replica_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -110,9 +124,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}', } ], - deprecated_rule=deprecated_replica_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -125,9 +137,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}', } ], - deprecated_rule=deprecated_replica_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'force_delete', @@ -140,9 +150,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}/action', } ], - deprecated_rule=deprecated_replica_force_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_force_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'promote', @@ -155,9 +163,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}/action', } ], - deprecated_rule=deprecated_replica_promote, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_promote ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'resync', @@ -170,9 +176,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}/action', } ], - deprecated_rule=deprecated_replica_resync, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_resync ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_replica_state', @@ -185,9 +189,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}/action', } ], - deprecated_rule=deprecated_replica_reset_state, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_reset_state ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -200,9 +202,7 @@ share_replica_policies = [ 'path': '/share-replicas/{share_replica_id}/action', } ], - deprecated_rule=deprecated_replica_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_reset_status ), ] diff --git a/manila/policies/share_replica_export_location.py b/manila/policies/share_replica_export_location.py index 8dac7b9b23..0ec426e01f 100644 --- a/manila/policies/share_replica_export_location.py +++ b/manila/policies/share_replica_export_location.py @@ -25,11 +25,15 @@ roles. deprecated_replica_location_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_replica_location_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -45,9 +49,7 @@ share_replica_export_location_policies = [ 'path': '/share-replicas/{share_replica_id}/export-locations', } ], - deprecated_rule=deprecated_replica_location_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_location_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -62,9 +64,7 @@ share_replica_export_location_policies = [ '{export_location_id}'), } ], - deprecated_rule=deprecated_replica_location_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_replica_location_show ), ] diff --git a/manila/policies/share_server.py b/manila/policies/share_server.py index e82f790232..0a7cf3933f 100644 --- a/manila/policies/share_server.py +++ b/manila/policies/share_server.py @@ -24,55 +24,81 @@ The share server API now supports system scope and default roles. deprecated_server_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_details = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'details', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_manage_server = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'manage_share_server', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_unmanage_server = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'unmanage_share_server', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_migration_start = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'share_server_migration_start', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_migration_check = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'share_server_migration_check', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_migration_complete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'share_server_migration_complete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_migration_cancel = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'share_server_migration_cancel', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_migration_get_progress = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'share_server_migration_get_progress', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_server_reset_task_state = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'share_server_reset_task_state', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -92,9 +118,7 @@ share_server_policies = [ 'path': '/share-servers?{query}', } ], - deprecated_rule=deprecated_server_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -107,9 +131,7 @@ share_server_policies = [ 'path': '/share-servers/{server_id}', } ], - deprecated_rule=deprecated_server_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'details', @@ -122,9 +144,7 @@ share_server_policies = [ 'path': '/share-servers/{server_id}/details', } ], - deprecated_rule=deprecated_server_details, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_details ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -137,9 +157,7 @@ share_server_policies = [ 'path': '/share-servers/{server_id}', } ], - deprecated_rule=deprecated_server_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'manage_share_server', @@ -152,9 +170,7 @@ share_server_policies = [ 'path': '/share-servers/manage' } ], - deprecated_rule=deprecated_manage_server, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_manage_server ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'unmanage_share_server', @@ -167,9 +183,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action' } ], - deprecated_rule=deprecated_unmanage_server, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_unmanage_server ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -182,9 +196,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action' } ], - deprecated_rule=deprecated_server_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_reset_status ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'share_server_migration_start', @@ -197,9 +209,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action', } ], - deprecated_rule=deprecated_server_migration_start, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_migration_start ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'share_server_migration_check', @@ -213,9 +223,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action', } ], - deprecated_rule=deprecated_server_migration_check, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_migration_check ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'share_server_migration_complete', @@ -228,9 +236,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action', } ], - deprecated_rule=deprecated_server_migration_complete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_migration_complete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'share_server_migration_cancel', @@ -243,9 +249,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action', } ], - deprecated_rule=deprecated_server_migration_cancel, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_migration_cancel ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'share_server_migration_get_progress', @@ -259,9 +263,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action', } ], - deprecated_rule=deprecated_server_migration_get_progress, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_migration_get_progress ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'share_server_reset_task_state', @@ -274,9 +276,7 @@ share_server_policies = [ 'path': '/share-servers/{share_server_id}/action', } ], - deprecated_rule=deprecated_server_reset_task_state, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_server_reset_task_state ), ] diff --git a/manila/policies/share_snapshot.py b/manila/policies/share_snapshot.py index 16ba1cbd00..5b2106b4a3 100644 --- a/manila/policies/share_snapshot.py +++ b/manila/policies/share_snapshot.py @@ -24,39 +24,57 @@ The share snapshot API now supports system scope and default roles. deprecated_snapshot_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_snapshot', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all_snapshots', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_force_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'force_delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_manage = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'manage_snapshot', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_unmanage = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'unmanage_snapshot', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_access_list = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'access_list', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_allow_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'allow_access', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_deny_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'deny_access', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -72,9 +90,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}' } ], - deprecated_rule=deprecated_snapshot_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all_snapshots', @@ -99,9 +115,7 @@ share_snapshot_policies = [ 'path': '/snapshots/detail?{query}' } ], - deprecated_rule=deprecated_snapshot_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'force_delete', @@ -114,9 +128,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}' } ], - deprecated_rule=deprecated_snapshot_force_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_force_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'manage_snapshot', @@ -129,9 +141,7 @@ share_snapshot_policies = [ 'path': '/snapshots/manage' } ], - deprecated_rule=deprecated_snapshot_manage, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_manage ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'unmanage_snapshot', @@ -144,9 +154,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}/action' } ], - deprecated_rule=deprecated_snapshot_unmanage, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_unmanage ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -159,9 +167,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}/action', } ], - deprecated_rule=deprecated_snapshot_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_reset_status ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'access_list', @@ -174,9 +180,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}/access-list' } ], - deprecated_rule=deprecated_snapshot_access_list, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_access_list ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'allow_access', @@ -189,9 +193,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}/action' } ], - deprecated_rule=deprecated_snapshot_allow_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_allow_access ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'deny_access', @@ -204,9 +206,7 @@ share_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}/action' } ], - deprecated_rule=deprecated_snapshot_deny_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_deny_access ), ] diff --git a/manila/policies/share_snapshot_export_location.py b/manila/policies/share_snapshot_export_location.py index b830058575..ba8768ef88 100644 --- a/manila/policies/share_snapshot_export_location.py +++ b/manila/policies/share_snapshot_export_location.py @@ -24,11 +24,15 @@ The share snapshot location API now supports system scope and default roles. deprecated_snapshot_location_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_location_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -44,9 +48,7 @@ share_snapshot_export_location_policies = [ 'path': '/snapshots/{snapshot_id}/export-locations/', } ], - deprecated_rule=deprecated_snapshot_location_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_location_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -61,9 +63,7 @@ share_snapshot_export_location_policies = [ 'export-locations/{export_location_id}'), } ], - deprecated_rule=deprecated_snapshot_location_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_location_show ), ] diff --git a/manila/policies/share_snapshot_instance.py b/manila/policies/share_snapshot_instance.py index 3400503268..26641fbad4 100644 --- a/manila/policies/share_snapshot_instance.py +++ b/manila/policies/share_snapshot_instance.py @@ -24,19 +24,27 @@ The share snapshot instance API now supports system scope and default roles. deprecated_snapshot_instance_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_instance_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_instance_detail = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'detail', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_instance_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -52,9 +60,7 @@ share_snapshot_instance_policies = [ 'path': '/snapshot-instances/{snapshot_instance_id}', } ], - deprecated_rule=deprecated_snapshot_instance_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_instance_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -71,9 +77,7 @@ share_snapshot_instance_policies = [ 'path': '/snapshot-instances?{query}', }, ], - deprecated_rule=deprecated_snapshot_instance_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_instance_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'detail', @@ -90,9 +94,7 @@ share_snapshot_instance_policies = [ 'path': '/snapshot-instances/detail?{query}', }, ], - deprecated_rule=deprecated_snapshot_instance_detail, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_instance_detail ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -105,9 +107,7 @@ share_snapshot_instance_policies = [ 'path': '/snapshot-instances/{snapshot_instance_id}/action', } ], - deprecated_rule=deprecated_snapshot_instance_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_instance_reset_status ), ] diff --git a/manila/policies/share_snapshot_instance_export_location.py b/manila/policies/share_snapshot_instance_export_location.py index 4e48b78208..5968940696 100644 --- a/manila/policies/share_snapshot_instance_export_location.py +++ b/manila/policies/share_snapshot_instance_export_location.py @@ -25,11 +25,15 @@ default roles. deprecated_snapshot_instance_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_snapshot_instance_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -46,9 +50,7 @@ share_snapshot_instance_export_location_policies = [ 'export-locations'), } ], - deprecated_rule=deprecated_snapshot_instance_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_instance_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -63,9 +65,7 @@ share_snapshot_instance_export_location_policies = [ 'export-locations/{export_location_id}'), } ], - deprecated_rule=deprecated_snapshot_instance_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_snapshot_instance_show ), ] diff --git a/manila/policies/share_type.py b/manila/policies/share_type.py index d2ce10d406..964a5a8c07 100644 --- a/manila/policies/share_type.py +++ b/manila/policies/share_type.py @@ -27,39 +27,57 @@ The share type API now supports system scope and default roles. deprecated_share_type_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_get_default = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'default', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_list_project_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'list_project_access', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_add_project_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'add_project_access', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_type_remove_project_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'remove_project_access', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -75,9 +93,7 @@ share_type_policies = [ 'path': '/types', } ], - deprecated_rule=deprecated_share_type_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -90,9 +106,7 @@ share_type_policies = [ 'path': '/types/{share_type_id}', } ], - deprecated_rule=deprecated_share_type_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -105,9 +119,7 @@ share_type_policies = [ 'path': '/types/{share_type_id}', } ], - deprecated_rule=deprecated_share_type_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -124,9 +136,7 @@ share_type_policies = [ 'path': '/types?is_public=all', } ], - deprecated_rule=deprecated_share_type_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'default', @@ -139,9 +149,7 @@ share_type_policies = [ 'path': '/types/default', } ], - deprecated_rule=deprecated_share_type_get_default, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_get_default ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -154,9 +162,7 @@ share_type_policies = [ 'path': '/types/{share_type_id}', } ], - deprecated_rule=deprecated_share_type_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'list_project_access', @@ -169,9 +175,7 @@ share_type_policies = [ 'path': '/types/{share_type_id}', } ], - deprecated_rule=deprecated_share_type_list_project_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_list_project_access ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'add_project_access', @@ -184,9 +188,7 @@ share_type_policies = [ 'path': '/types/{share_type_id}/action', } ], - deprecated_rule=deprecated_share_type_add_project_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_add_project_access ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'remove_project_access', @@ -199,9 +201,7 @@ share_type_policies = [ 'path': '/types/{share_type_id}/action', } ], - deprecated_rule=deprecated_share_type_remove_project_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_type_remove_project_access ), ] diff --git a/manila/policies/share_types_extra_spec.py b/manila/policies/share_types_extra_spec.py index 51bb36cfb0..e55cf7e8f9 100644 --- a/manila/policies/share_types_extra_spec.py +++ b/manila/policies/share_types_extra_spec.py @@ -24,23 +24,33 @@ The share types extra specs API now supports system scope and default roles. deprecated_extra_spec_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_extra_spec_show = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'show', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_extra_spec_index = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'index', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_extra_spec_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_extra_spec_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -56,9 +66,7 @@ share_types_extra_spec_policies = [ 'path': '/types/{share_type_id}/extra_specs', } ], - deprecated_rule=deprecated_extra_spec_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_extra_spec_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'show', @@ -71,9 +79,7 @@ share_types_extra_spec_policies = [ 'path': '/types/{share_type_id}/extra_specs', } ], - deprecated_rule=deprecated_extra_spec_show, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_extra_spec_show ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'index', @@ -86,9 +92,7 @@ share_types_extra_spec_policies = [ 'path': '/types/{share_type_id}/extra_specs/{extra_spec_id}', }, ], - deprecated_rule=deprecated_extra_spec_index, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_extra_spec_index ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -101,9 +105,7 @@ share_types_extra_spec_policies = [ 'path': '/types/{share_type_id}/extra_specs', } ], - deprecated_rule=deprecated_extra_spec_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_extra_spec_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -116,9 +118,7 @@ share_types_extra_spec_policies = [ 'path': '/types/{share_type_id}/extra_specs/{key}', } ], - deprecated_rule=deprecated_extra_spec_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_extra_spec_delete ), ] diff --git a/manila/policies/shares.py b/manila/policies/shares.py index 829298dafc..e0fb2cf79f 100644 --- a/manila/policies/shares.py +++ b/manila/policies/shares.py @@ -25,129 +25,191 @@ The share API now supports system scope and default roles. # Deprecated share policies deprecated_share_create = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create', - check_str="" + check_str="", + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_create_public = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create_public_share', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_all', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_set_public = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'set_public_share', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_force_delete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'force_delete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_manage = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'manage', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_unmanage = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'unmanage', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_list_by_host = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'list_by_host', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_list_by_server_id = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'list_by_share_server_id', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_access_get = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'access_get', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_access_get_all = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'access_get_all', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_extend = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'extend', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_shrink = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'shrink', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_migration_start = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'migration_start', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_migration_complete = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'migration_complete', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_migration_cancel = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'migration_cancel', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_migration_get_progress = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'migration_get_progress', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_reset_task_state = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_task_state', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_reset_status = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'reset_status', - check_str=base.RULE_ADMIN_API + check_str=base.RULE_ADMIN_API, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_revert_to_snapshot = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'revert_to_snapshot', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_allow_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'allow_access', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_deny_access = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'deny_access', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_update_metadata = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'update_share_metadata', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_delete_metadata = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete_share_metadata', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_get_metadata = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'get_share_metadata', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) # deprecated legacy snapshot policies with "share" as base resource deprecated_share_create_snapshot = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'create_snapshot', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_delete_snapshot = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'delete_snapshot', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) deprecated_share_snapshot_update = policy.DeprecatedRule( name=BASE_POLICY_NAME % 'snapshot_update', - check_str=base.RULE_DEFAULT + check_str=base.RULE_DEFAULT, + deprecated_reason=DEPRECATED_REASON, + deprecated_since=versionutils.deprecated.WALLABY ) @@ -163,9 +225,7 @@ shares_policies = [ 'path': '/shares', } ], - deprecated_rule=deprecated_share_create, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_create ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'create_public_share', @@ -178,9 +238,7 @@ shares_policies = [ 'path': '/shares', } ], - deprecated_rule=deprecated_share_create_public, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_create_public ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get', @@ -193,9 +251,7 @@ shares_policies = [ 'path': '/shares/{share_id}', } ], - deprecated_rule=deprecated_share_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_all', @@ -212,9 +268,7 @@ shares_policies = [ 'path': '/shares/detail', } ], - deprecated_rule=deprecated_share_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update', @@ -227,9 +281,7 @@ shares_policies = [ 'path': '/shares', } ], - deprecated_rule=deprecated_share_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_update ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'set_public_share', @@ -243,9 +295,7 @@ shares_policies = [ 'path': '/shares', } ], - deprecated_rule=deprecated_share_set_public, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_set_public ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete', @@ -258,9 +308,7 @@ shares_policies = [ 'path': '/shares/{share_id}', } ], - deprecated_rule=deprecated_share_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'force_delete', @@ -273,9 +321,7 @@ shares_policies = [ 'path': '/shares/{share_id}', } ], - deprecated_rule=deprecated_share_force_delete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_force_delete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'manage', @@ -288,9 +334,7 @@ shares_policies = [ 'path': '/shares/manage', } ], - deprecated_rule=deprecated_share_manage, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_manage ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'unmanage', @@ -303,9 +347,7 @@ shares_policies = [ 'path': '/shares/unmanage', } ], - deprecated_rule=deprecated_share_unmanage, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_unmanage ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'list_by_host', @@ -322,9 +364,7 @@ shares_policies = [ 'path': '/shares/detail', } ], - deprecated_rule=deprecated_share_list_by_host, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_list_by_host ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'list_by_share_server_id', @@ -341,9 +381,7 @@ shares_policies = [ 'path': '/shares/detail', } ], - deprecated_rule=deprecated_share_list_by_server_id, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_list_by_server_id ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'access_get', @@ -356,9 +394,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_access_get, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_access_get ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'access_get_all', @@ -371,9 +407,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_access_get_all, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_access_get_all ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'extend', @@ -386,9 +420,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_extend, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_extend ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'shrink', @@ -401,9 +433,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_shrink, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_shrink ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'migration_start', @@ -416,9 +446,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_migration_start, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_migration_start ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'migration_complete', @@ -431,9 +459,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_migration_complete, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_migration_complete ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'migration_cancel', @@ -446,9 +472,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_migration_cancel, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_migration_cancel ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'migration_get_progress', @@ -462,9 +486,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_migration_get_progress, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_migration_get_progress ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_task_state', @@ -477,9 +499,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_reset_task_state, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_reset_task_state ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'reset_status', @@ -492,9 +512,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_reset_status, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_reset_status ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'revert_to_snapshot', @@ -507,9 +525,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_revert_to_snapshot, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_revert_to_snapshot ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'allow_access', @@ -522,9 +538,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_allow_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_allow_access ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'deny_access', @@ -537,9 +551,7 @@ shares_policies = [ 'path': '/shares/{share_id}/action', } ], - deprecated_rule=deprecated_share_deny_access, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_deny_access ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'update_share_metadata', @@ -552,9 +564,7 @@ shares_policies = [ 'path': '/shares/{share_id}/metadata', } ], - deprecated_rule=deprecated_share_update_metadata, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_update_metadata ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete_share_metadata', @@ -567,9 +577,7 @@ shares_policies = [ 'path': '/shares/{share_id}/metadata/{key}', } ], - deprecated_rule=deprecated_share_delete_metadata, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_delete_metadata ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'get_share_metadata', @@ -582,9 +590,7 @@ shares_policies = [ 'path': '/shares/{share_id}/metadata', } ], - deprecated_rule=deprecated_share_get_metadata, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_get_metadata ), ] @@ -603,9 +609,7 @@ base_snapshot_policies = [ 'path': '/snapshots', } ], - deprecated_rule=deprecated_share_create_snapshot, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_create_snapshot ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'delete_snapshot', @@ -618,9 +622,7 @@ base_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}', } ], - deprecated_rule=deprecated_share_delete_snapshot, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_delete_snapshot ), policy.DocumentedRuleDefault( name=BASE_POLICY_NAME % 'snapshot_update', @@ -633,9 +635,7 @@ base_snapshot_policies = [ 'path': '/snapshots/{snapshot_id}/action', } ], - deprecated_rule=deprecated_share_snapshot_update, - deprecated_reason=DEPRECATED_REASON, - deprecated_since=versionutils.deprecated.WALLABY + deprecated_rule=deprecated_share_snapshot_update ), ] diff --git a/requirements.txt b/requirements.txt index 638607c8bc..2c4b275cca 100644 --- a/requirements.txt +++ b/requirements.txt @@ -17,7 +17,7 @@ oslo.i18n>=5.0.1 # Apache-2.0 oslo.log>=4.4.0 # Apache-2.0 oslo.messaging>=12.5.0 # Apache-2.0 oslo.middleware>=4.1.1 # Apache-2.0 -oslo.policy>=3.6.2 # Apache-2.0 +oslo.policy>=3.7.0 # Apache-2.0 oslo.reports>=2.2.0 # Apache-2.0 oslo.rootwrap>=6.2.0 # Apache-2.0 oslo.serialization>=4.0.1 # Apache-2.0