openstack.network.v2.metering_label_rule¶
MeteringLabelRule 类¶
MeteringLabelRule 类继承自 Resource。
- class openstack.network.v2.metering_label_rule.MeteringLabelRule(_synchronized=False, connection=None, **attrs)¶
基础资源
- 参数:
_synchronized (bool) – 这不打算直接使用。请参阅
new()和existing()。connection (openstack.connection.Connection) – 对正在使用的 Connection 的引用。默认为 None,允许在单元测试中等情况下使用不带活动 Connection 的 Resource 对象。Resource 代码中对
self._connection的使用应使用 None 检查进行保护。
- resource_key = 'metering_label_rule'¶
资源的单数形式的键。
- resources_key = 'metering_label_rules'¶
资源的复数形式的键。
- base_path = '/metering/metering-label-rules'¶
此资源的 URI 的基本部分。
- allow_create = True¶
允许对此资源进行创建操作。
- allow_fetch = True¶
允许对此资源进行获取操作。
- allow_commit = True¶
允许对此资源进行更新操作。
- allow_delete = True¶
允许对此资源进行删除操作。
- allow_list = True¶
允许对此资源进行列表操作。
- direction¶
ingress 或 egress:应用计量标签规则的方向。默认值:
"ingress"
- is_excluded¶
指定
remote_ip_prefix是否从计量标签的流量计数器中排除,即:是否不计算特定 IP 地址范围的流量。默认值:False,类型:bool
- metering_label_id¶
与此计量标签规则关联的计量标签 ID。
- project_id¶
此计量标签规则关联的项目 ID。
- tenant_id¶
租户 ID(已弃用的属性)。
- remote_ip_prefix¶
与此计量标签规则关联的远程 IP 前缀。
- source_ip_prefix¶
与此计量标签规则关联的源 IP 前缀。
- destination_ip_prefix¶
与此计量标签规则关联的目标 IP 前缀