Reputation: 3964
According to Mongo Atlas integration with AWS's best practices page, AWS Lambda's callbackWaitsForEmptyEventLoop
's value should be set to false
but I can't find this property in .NET SDK.
Is this specific to NodeJS or is it available in .NET too?
Upvotes: 1
Views: 2538
Reputation: 8474
The context
given to each lambda function is specific to each language (You can read about the C# one here).
callbackWaitsForEmptyEventLoop
is unique to NodeJS, because of the various ways lambda can detects that a node handler has completed and is returning a response. In the case of Atlas' best practice, this is suggested because if you use the persistent scope outside the handler to pool a connection between invocations, lambda will halt waiting for the socket to close (empty the event loop).e
.NET has its own way of explicitly determining when to return.
Upvotes: 1