mongoDB return response taking more time from AWS lambda

Sometimes it takes more than 10secs for the same query When I am fetching the data from MongoDB using AWS Lambda

1 Like

Hi Robot_Blue,

That is seriously bizarre: even for a net new connection, including TLS and authentication, you should never need more than 100ms. If the query takes multiple seconds to run that suggests it might be an unindexed query. Did you continue having this problem or work it out?

-Andrew

1 Like

Hello, I’m also facing this same issue. Even though I have created a search index on a collection but it is still taking 4 sec. Can you help me?

I am having this issue as well any new data on this? I also implemented reusing the same mongo db connection with lambda as well but the it still can be so slow

Same problem here. Lambda takes 15 sec to return results. Makes no sense :frowning: