Closed kcveitch closed 10 months ago
Hey, thanks for reaching out! I'm sorry you're running into an issue here.
In this case, I think this issue is best opened in dd-trace
as I don't think it runs through this package specifically. Would you mind opening an issue there?
Thanks!
no problem. I debated putting it there :)
Just a note for future readers:
looks like I may have jumped the gun on this being caused by 99. let it run for 24 hours on 98 with ext 50 and still seeing the issue. looks like it might have been introduced by the agent update. Moving this ticket over to that project after I confirm that downgrading to 49 indeed resolves it.
nope was right the first time. got my deployment environments crossed
issue reposted on dd-trace-js project here: https://github.com/DataDog/dd-trace-js/issues/3793
updating from layer 98 to layer 99 introduces an intermittent postgres error with prepared statements.
Error: Prepared statements must be unique - 'InsertMarketNotifications' was used for a different statement
This appears to occur when multiple invocations of a lambda are happening in rapid sequence. In this case one lambda is processing a SQS queue of a few dozen records and are posting them to a REST API Gateway which is invoking another lambda to process and insert records into postgres. The lambda being invoked from the API Gateway to insert records into postges is the one experiencing the errors and is configured with the following settings.
It appears that the first few invocations are able to make their inserts into pg without error but as more invocations come in, the error begins to occur consistently until all invocations fail in the same way.
We are using a few DD products in BETA such as serverless profiling and ASM which could be related to the issue.
reverting to nodeLayerVersion 98 corrects the issue and the error no longer occurs
Specifications
Stack Trace