Checkboxes for prior research
Describe the bug
With "@aws-sdk/client-s3": "3.830.0" I have often a socket hangup at the first HEAD Command. There is no fucntionnal impact since the retry works well and genrally the second HEAD Command is successful.
If I downgrade the version to my previous version in production "@aws-sdk/client-s3": "3.777.0" the error is not reprodcutible.
I try several tuning with the S3 Client.
First one :
this.client = new S3Client({
region: REGION,
requestHandler: new NodeHttpHandler({
httpsAgent: new Agent({ keepAlive: true, keepAliveMsecs: 2000, timeout: 10000, maxSockets: 400 }),
connectionTimeout: 30 * 1000, // 30 seconds
requestTimeout: 60 * 1000, // 1 minute
}),
Second one:
this.client = new S3Client({
region: REGION,
requestHandler: new NodeHttpHandler({
httpsAgent: new Agent({ keepAlive: true, keepAliveMsecs: 2000, timeout: 10000, maxSockets: 50 }),
connectionTimeout: 30 * 1000, // 30 seconds
requestTimeout: 60 * 1000, // 1 minute
}),
Here the global runtime configuration
const LAMBDA_RUNTIME = 'nodejs22.x'
const DATADOG_LAYER_ARN = 'arn:aws:lambda:eu-west-3:464622532012:layer:Datadog-Node22-x:124' // See https://github.com/DataDog/datadog-lambda-js/releases
const DATADOG_LAYER_EXTENSION_ARN = 'arn:aws:lambda:eu-west-3:464622532012:layer:Datadog-Extension:77' // See https://github.com/DataDog/datadog-lambda-extension/releases
Regression Issue
SDK version number
"@aws-sdk/client-s3": "3.830.0"
Which JavaScript Runtime is this issue in?
Node.js
Details of the browser/Node.js/ReactNative version
node runtime 22
Reproduction Steps
How to reproduce.
- deploy a lambda with a HEAD Command which is triggered with S3 events
- Upload several Object in the bucket using the aws console
Observed Behavior
- The first HEAD Command observe 'socket hangup' error with S3 Service randomly , the second call is always succcessful
Expected Behavior
No 'socket hangup' observed
Possible Solution
I think that my S3 client is not well tuned but I did not fine how to do it.
Additional Information/Context
No response
Checkboxes for prior research
Describe the bug
With "@aws-sdk/client-s3": "3.830.0" I have often a socket hangup at the first HEAD Command. There is no fucntionnal impact since the retry works well and genrally the second HEAD Command is successful.
If I downgrade the version to my previous version in production "@aws-sdk/client-s3": "3.777.0" the error is not reprodcutible.
I try several tuning with the S3 Client.
First one :
Second one:
Here the global runtime configuration
Regression Issue
SDK version number
"@aws-sdk/client-s3": "3.830.0"
Which JavaScript Runtime is this issue in?
Node.js
Details of the browser/Node.js/ReactNative version
node runtime 22
Reproduction Steps
How to reproduce.
Observed Behavior
Expected Behavior
No 'socket hangup' observed
Possible Solution
I think that my S3 client is not well tuned but I did not fine how to do it.
Additional Information/Context
No response