Queries the detailed information about a routing rule of an Alibaba Cloud Service Mesh (ASM) gateway.
Debugging
Request parameters
| Parameter | Type | Required | Example | Description |
|---|---|---|---|---|
| Action | String | Yes | DescribeIstioGatewayRouteDetail |
The operation that you want to perform. Set the value to DescribeIstioGatewayRouteDetail. |
| ServiceMeshId | String | Yes | c08ba3fd1e6484b0f8cc1ad8fe10d**** |
The ID of the ASM instance. |
| IstioGatewayName | String | No | ingressgateway |
The name of the ASM gateway. |
| RouteName | String | No | demo-route |
The name of the routing rule. |
Response parameters
| Parameter | Type | Example | Description |
|---|---|---|---|
| RouteDetail | Object |
The detailed information about the routing rule. |
|
| RouteName | String | demo-route |
The name of the routing rule. |
| RouteType | String | HTTP |
The type of the traffic to be routed. Valid values: |
| MatchRequest | Object |
The matching rules for traffic routing. |
|
| URI | Object |
The matching rule for URLs. |
|
| MatchingMode | String | prefix |
The matching mode. Valid values:
|
| MatchingContent | String | /ratings/v2/ |
The content to be matched. |
| Headers | Array of header |
The request headers to be matched. |
|
| Name | String | x-request-id |
The header key to be matched. |
| MatchingMode | String | exact |
The matching mode for the header value. Valid values:
|
| MatchingContent | String | v1 |
The header value to be matched. |
| TLSMatchAttributes | Array of tlsMatchAttribute |
The matching rule for TLS traffic. |
|
| TLSPort | Integer | 443 |
The TLS port. |
| SNIHosts | Array of String | *.com |
The Server Name Indication (SNI) values to be matched. Wildcards can be used as the
prefix of an SNI value. For example, a value of Note The SNI values must be a subset of the hostnames of the corresponding virtual hosts.
|
| Ports | Array of Integer | 443 |
The ports of the specified hosts to which the traffic is routed. |
| HTTPAdvancedOptions | Object |
The advanced settings for routing HTTP traffic. |
|
| HTTPRedirect | Object |
The HTTP redirect rule. |
|
| Uri | String | /v1/getProductRatings |
The value to be used to overwrite the URL path during redirection. |
| Authority | String | newratings.default.svc.cluster.local |
The value to be used to overwrite the value of the Authority or Host header during redirection. |
| RedirectCode | Integer | 301 |
The response code to be used for indicating URL redirection. Default value: 301. |
| Delegate | Object |
The virtual service that defines traffic routing. |
|
| Name | String | reviews |
The name of the virtual service. |
| Namespace | String | default |
The namespace to which the virtual service belongs. |
| Rewrite | Object |
The configurations for rewriting virtual service. |
|
| Uri | String | /v1/getProductRatings |
The value to be used to overwrite the path or prefix of the URL. |
| Authority | String | newratings.default.svc.cluster.local |
The value to be used to overwrite the value of the Authority or Host header. |
| Timeout | String | 5s |
The timeout period for requests. |
| Retries | Object |
The configurations of retries for failed requests. |
|
| Attempts | Integer | 3 |
The maximum number of retries that are allowed for a request. |
| PerTryTimeout | String | 2s |
The timeout period for each retry. |
| RetryOn | String | connect-failure,refused-stream,503 |
The condition for retries. Example: |
| RetryRemoteLocalities | Object |
Specifies whether to allow retries to other localities. |
|
| Value | Boolean | false |
Specifies whether to allow retries to other localities. Valid values:
Default value: |
| Fault | Object |
The configurations of fault injection. |
|
| Delay | Object |
The duration to delay a request. |
|
| FixedDelay | String | 5s |
The fixed duration for request delay. |
| ExponentialDelay | String | 3 |
The duration for request delay is expressed as 2 raised to the power of x. You must specify the value of x. |
| Percentage | Object |
The percentage of requests to which the delay fault is injected. |
|
| Value | Float | 0.1 |
The percentage of requests that are aborted with specified error codes, expressed as a decimal. |
| Abort | Object |
The configurations for aborting requests with specified error codes. |
|
| HttpStatus | Integer | 400 |
The specified HTTP error code. |
| Percentage | Object |
The percentage of requests that are aborted with the specified error code. |
|
| Value | Float | 0.1 |
The percentage of requests that are aborted with the specified error code, expressed as a decimal. |
| Mirror | Object |
The configurations for mirroring HTTP traffic to another destination in addition to forwarding requests to the specified destination. |
|
| Host | String | reviews.default.svc.cluster.local |
The name of the service defined in the service registry. |
| Subset | String | v1 |
The name of the service subset. |
| MirrorPercentage | Object |
The percentage of requests that are mirrored to another destination except for the original destination. |
|
| Value | Float | 0.2 |
The percentage of requests that are mirrored to another destination except for the original destination, expressed as a decimal. |
| RouteDestinations | Array of routeDestination |
The endpoints of service instances for Layer 4 weighted routing. |
|
| Destination | Object |
The unique endpoint of the service instance to which the specified requests are sent. |
|
| Host | String | reviews |
The name of the service defined in the service registry. |
| Subset | String | v1 |
The name of the service subset. |
| Port | Object |
The ports of the specified hosts from which the traffic is routed. |
|
| Number | Integer | 443 |
The port of the specified host to which the traffic is routed. |
| Weight | Integer | 80 |
The traffic weight. Valid values: 1 to 100. |
| Headers | Object |
The request headers to be matched. |
|
| Request | Object |
The request header to be matched. |
|
| Set | Map |
The header key to be used to overwrite the original header key. |
|
| String | key |
The header key that you specify. |
|
| Add | Map |
The values to be added to the header key. |
|
| Remove | Array of String | key |
The key to be deleted. |
| Response | Object |
The processing of the headers of the response that is to be returned. |
|
| Set | Map |
The header key to be used to overwrite the original header key. |
|
| Add | Map |
The values to be added to the header key. |
|
| Remove | Array of String | key |
The key to be deleted. |
| RequestId | String | 31d3a0f0-07ed-4f6e-9004-1804498c**** |
The ID of the request. |
| Priority | Integer | 1 |
The priority of the routing rule. The value of this parameter is an integer. A smaller value indicates a higher priority. |
| Status | Integer | 1 |
The status of the routing rule. Valid values:
|
| Description | String | demo route |
The description of the routing rule. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=DescribeIstioGatewayRouteDetail
&ServiceMeshId=c08ba3fd1e6484b0f8cc1ad8fe10d****
&IstioGatewayName=ingressgateway
&RouteName=demo-route
&<Common request parameters>
Sample success responses
XML format
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeIstioGatewayRouteDetailResponse>
<RouteDetail>
<RouteName>demo-route</RouteName>
<RouteType>HTTP</RouteType>
<MatchRequest>
<URI>
<MatchingMode>prefix</MatchingMode>
<MatchingContent>/ratings/v2/</MatchingContent>
</URI>
<Headers>
<Name>x-request-id</Name>
<MatchingMode>exact</MatchingMode>
<MatchingContent>v1</MatchingContent>
</Headers>
<TLSMatchAttributes>
<TLSPort>443</TLSPort>
<SNIHosts>*.com</SNIHosts>
</TLSMatchAttributes>
<Ports>443</Ports>
</MatchRequest>
<HTTPAdvancedOptions>
<HTTPRedirect>
<Uri>/v1/getProductRatings</Uri>
<Authority>newratings.default.svc.cluster.local</Authority>
<RedirectCode>301</RedirectCode>
</HTTPRedirect>
<Delegate>
<Name>reviews</Name>
<Namespace>default</Namespace>
</Delegate>
<Rewrite>
<Uri>/v1/getProductRatings</Uri>
<Authority>newratings.default.svc.cluster.local</Authority>
</Rewrite>
<Timeout>5s</Timeout>
<Retries>
<Attempts>3</Attempts>
<PerTryTimeout>2s</PerTryTimeout>
<RetryOn>connect-failure,refused-stream,503</RetryOn>
<RetryRemoteLocalities>
<Value>false</Value>
</RetryRemoteLocalities>
</Retries>
<Fault>
<Delay>
<FixedDelay>5s</FixedDelay>
<ExponentialDelay>3</ExponentialDelay>
<Percentage>
<Value>0.1</Value>
</Percentage>
</Delay>
<Abort>
<HttpStatus>400</HttpStatus>
<Percentage>
<Value>0.1</Value>
</Percentage>
</Abort>
</Fault>
<Mirror>
<Host>reviews.default.svc.cluster.local</Host>
<Subset>v1</Subset>
</Mirror>
<MirrorPercentage>
<Value>0.2</Value>
</MirrorPercentage>
</HTTPAdvancedOptions>
<RouteDestinations>
<Destination>
<Host>reviews</Host>
<Subset>v1</Subset>
<Port>
<Number>443</Number>
</Port>
</Destination>
<Weight>80</Weight>
<Headers>
<Request>
<Set>
<key>key</key>
</Set>
<Remove>key</Remove>
</Request>
<Response>
<Remove>key</Remove>
</Response>
</Headers>
</RouteDestinations>
</RouteDetail>
<RequestId>31d3a0f0-07ed-4f6e-9004-1804498c****</RequestId>
<Priority>1</Priority>
<Status>1</Status>
<Description>demo route</Description>
</DescribeIstioGatewayRouteDetailResponse>
JSON format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RouteDetail" : {
"RouteName" : "demo-route",
"RouteType" : "HTTP",
"MatchRequest" : {
"URI" : {
"MatchingMode" : "prefix",
"MatchingContent" : "/ratings/v2/"
},
"Headers" : {
"Name" : "x-request-id",
"MatchingMode" : "exact",
"MatchingContent" : "v1"
},
"TLSMatchAttributes" : {
"TLSPort" : 443,
"SNIHosts" : "*.com"
},
"Ports" : 443
},
"HTTPAdvancedOptions" : {
"HTTPRedirect" : {
"Uri" : "/v1/getProductRatings",
"Authority" : "newratings.default.svc.cluster.local",
"RedirectCode" : 301
},
"Delegate" : {
"Name" : "reviews",
"Namespace" : "default"
},
"Rewrite" : {
"Uri" : "/v1/getProductRatings",
"Authority" : "newratings.default.svc.cluster.local"
},
"Timeout" : "5s",
"Retries" : {
"Attempts" : 3,
"PerTryTimeout" : "2s",
"RetryOn" : "connect-failure,refused-stream,503",
"RetryRemoteLocalities" : {
"Value" : false
}
},
"Fault" : {
"Delay" : {
"FixedDelay" : "5s",
"ExponentialDelay" : 3,
"Percentage" : {
"Value" : 0.1
}
},
"Abort" : {
"HttpStatus" : 400,
"Percentage" : {
"Value" : 0.1
}
}
},
"Mirror" : {
"Host" : "reviews.default.svc.cluster.local",
"Subset" : "v1"
},
"MirrorPercentage" : {
"Value" : 0.2
}
},
"RouteDestinations" : {
"Destination" : {
"Host" : "reviews",
"Subset" : "v1",
"Port" : {
"Number" : 443
}
},
"Weight" : 80,
"Headers" : {
"Request" : {
"Set" : {
"key" : "key"
},
"Remove" : "key"
},
"Response" : {
"Remove" : "key"
}
}
}
},
"RequestId" : "31d3a0f0-07ed-4f6e-9004-1804498c****",
"Priority" : 1,
"Status" : 1,
"Description" : "demo route"
}
Error codes
| HTTP status code | Error code | Error message | Description |
|---|---|---|---|
| 500 | ERR500 | An internal server error occurred. | The error message returned because a backend service error has occurred. |
For a list of error codes, visit the API Error Center.