调用DescribeRuleAttribute查询指定转发规则的配置详情。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
请求参数
名称 | 类型 | 是否必选 | 示例值 | 描述 |
---|---|---|---|---|
Action | String | 是 | DescribeRuleAttribute |
要执行的操作。 取值:DescribeRuleAttribute。 |
RegionId | String | 是 | cn-hangzhou |
负载均衡实例的地域ID。 您可以通过调用DescribeRegions接口查询地域ID。 |
RuleId | String | 是 | rule-bp1efemp9suk5 |
转发规则ID。 |
返回数据
名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
RuleName | String | Rule1 |
转发规则名称。 |
LoadBalancerId | String | lb-bp1ca0zt07t934wxezyxo |
负载均衡实例ID。 |
ListenerPort | String | 90 |
负载均衡实例前端使用的监听端口。 |
Domain | String | test.com |
转发规则域名。 |
Url | String | /cache |
转发规则路径。 |
VServerGroupId | String | rsp-cige6j5e7p |
转发规则关联的服务器组ID。 |
Cookie | String | wwe |
服务器上配置的Cookie。 长度为1-200个字符,只能包含ASCII英文字母和数字字符,不能包含逗号、分号或空格,也不能以$开头。 当StickySession为on且StickySessionType为server时,该参数必选且有效。 |
CookieTimeout | Integer | 12 |
Cookie超时时间。 取值:1-86400(秒)。 |
HealthCheck | String | off |
是否开启健康检查。 取值:on | off。 |
HealthCheckConnectPort | Integer | 23 |
健康检查的后端服务器的端口。 取值:1-65535。 |
HealthCheckDomain | String | www.example.com |
用于健康检查的域名,取值:
|
HealthCheckHttpCode | String | http_3xx |
健康检查正常的HTTP状态码,多个状态码用逗号分隔。默认值为http_2xx。 取值:http_2xx | http_3xx | http_4xx | http_5xx。 |
HealthCheckInterval | Integer | 34 |
健康检查的时间间隔。 取值:1-50(秒)。 |
HealthCheckTimeout | Integer | 34 |
接收来自运行状况检查的响应需要等待的时间。如果后端ECS在指定的时间内没有正确响应,则判定为健康检查失败。 取值:1-300(秒)。 |
HealthCheckURI | String | 10.21.22.1 |
用于健康检查的URI。 |
HealthyThreshold | Integer | 2 |
健康检查连续成功多少次后,将后端服务器的健康检查状态由fail判定为success。 取值:2-10。 |
ListenerSync | String | off |
转发规则是否从监听上继承健康检查、会话保持和调度算法配置。 取值:on | off。
|
RequestId | String | 9DEC9C28-AB05-4DDF-9A78-6B08EC9CE18C |
请求ID。 |
RuleId | String | rule-hfgnd***** |
转发规则ID。 |
Scheduler | String | wrr |
调度算法。取值:
|
StickySession | String | off |
是否开启会话保持。 取值:on | off。 |
StickySessionType | String | insert |
cookie的处理方式。取值:
|
UnhealthyThreshold | Integer | 3 |
健康检查连续失败多少次后,将后端服务器的健康检查状态由success判定为fail。 取值:2-10 |
示例
请求示例
http(s)://[Endpoint]/?Action=DescribeRuleAttribute
&RegionId=cn-hangzhou
&RuleId=rule-bp1efemp9suk5
&<公共请求参数>
正常返回示例
XML
格式
<DescribeRuleAttributeResponse>
<Domain>test.com</Domain>
<VServerGroupId>rsp-bp114nimo4kl9</VServerGroupId>
<LoadBalancerId>lb-bp1ca0zt07t934wxezyxo</LoadBalancerId>
<RuleName>Rule2</RuleName>
<ListenerPort>90</ListenerPort>
<RequestId>DB3C28EE-9A6C-4FFA-8759-4ED8346A675E</RequestId>
<ListenerSync>on</ListenerSync>
</DescribeRuleAttributeResponse>
JSON
格式
{
"Domain":"test.com",
"RequestId":"DB3C28EE-9A6C-4FFA-8759-4ED8346A675E",
"VServerGroupId":"rsp-bp114nimo4kl9",
"LoadBalancerId":"lb-bp1ca0zt07t934wxezyxo",
"RuleName":"Rule2",
"ListenerSync":"on",
"ListenerPort":90
}
错误码
访问错误中心查看更多错误码。
原创文章,作者:网友投稿,如若转载,请注明出处:https://www.cloudads.cn/archives/33735.html