Cloud-native gateways allow you to configure timeout policies at the route level. If the gateway does not receive a response from the backend service within the specified period of time, the gateway returns the 504 (Gateway Timeout) status code to the client. This topic describes how to configure a route timeout policy for a cloud-native gateway.
Configure a timeout policy
Log on to the MSE console.
In the left-side navigation pane, choose Cloud-native Gateway > Gateways. In the top navigation bar, select a region.
On the Gateways page, find your gateway and click Route Settings in the Actions column. In the upper-right corner of the page that appears, click Previous Version.
In the left-side navigation pane, choose Routes > Route Settings. Find the routing rule that you want to modify, and click Policies in the Actions column.
In the Policies section of the page that appears, click the Timeout tab.
If no timeout policy exists, click Add Policy.
If a timeout policy already exists, click the icon.
In the Timeout rule, configure the parameters and click OK.
Parameters
Parameter
Description
Timeout Period
The timeout period for the current route. Unit: seconds.
NoteIf you set this parameter to 0 or keep the timeout policy disabled, the gateway waits for responses all the time.
Enable
Specifies whether to enable the timeout policy.
If you turn on the switch, the timeout policy takes effect.
If you turn off the switch, the timeout policy does not take effect.
After the timeout policy is created and enabled, you can verify the results based on your business requirements.