Does cosmos db cache the results? i.e. If we query cosmos db repeatedly for the same id, will we see the response time decreasing. I tried hitting cosmos db with the same id and observed response times of 500ms, 300ms, 31ms, 240ms,355ms respectively. As you can see the response time was all over the place and i could not draw any conclusions.
0
votes
1 Answers
0
votes
You probably experienced faster response time because query plans were cached. I think in your case there time was lowered for query compile time and query plan build. You wouldn't be able to lower the write output time since it's time it takes to copy the data.
I was not able to find any information that ComosDB caches the query results, so I wouldn't assume so.
You can look at the query metrics by using the .NET client docs.