Skip to content

Commit 089c230

Browse files
config(dev): adjust API connection timeout (#5754)
## Problem - The API connection was timing out after 120 seconds, leading to a poor customer experience (CX). Users were waiting for 2 minutes before receiving a timeout error, which is an unacceptably long wait time. ## Solution - Adjust the API connection timeout to 10 seconds, which is approximately 3 times the high band of the API's P99 latency. - This change should improve the user experience by failing fast in case of connection issues. --- <!--- REMINDER: Ensure that your PR meets the guidelines in CONTRIBUTING.md --> License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
1 parent db4bf31 commit 089c230

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/core/src/amazonqFeatureDev/client/featureDev.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ export async function createFeatureDevProxyClient(options?: Partial<ServiceOptio
4646
region: cwsprConfig.region,
4747
endpoint: cwsprConfig.endpoint,
4848
token: new Token({ token: bearerToken }),
49+
httpOptions: {
50+
connectTimeout: 10000, // 10 seconds, 3 times P99 API latency
51+
},
4952
...options,
5053
} as ServiceOptions,
5154
undefined

0 commit comments

Comments
 (0)