[SERVER-17333] Read performance dependency Created: 20/Feb/15  Updated: 20/Feb/15  Resolved: 20/Feb/15

Status: Closed
Project: Core Server
Component/s: Performance, Querying
Affects Version/s: 2.6.1
Fix Version/s: None

Type: Question Priority: Major - P3
Reporter: Himanshu Jain Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Description   

I have three collections sharded on 2 servers with date as shard key -

Collection A - 25 million documents with avg bsonSize: 700 bytes (10k -15k docs per day)

Collection B - 30 million documents with avg bsonSize: 500 bytes (12k -16k docs per day)

Collection C - 25 million documents with avg bsonSize: 1500 bytes (10k -15k docs per day)

Collection A & B gives decent (good) read performance like -
On first hit, for new date, i get records in almost 1 second (15k docs)
On second hit, it comes in 10-15 ms (due to cache)

But Collection C read performance is not as good -
On first hit, for new date, takes almost 50 seconds (15k docs, same number)
Second hit is fast as expected (5-10 ms)

Collection A & C are replica of each other in terms of Index and Shard Key. Only difference is collection A has fewer keys (50%) in comparison to collection C. And still so much difference in read performance?

This leads to conclusion - read performance depends on document size of collection. More the size is more time it will take to fetch documents on first hit (when not cached)..Is that right?

Any way to improve read performance of collection C ?

Thanks.



 Comments   
Comment by Ramon Fernandez Marina [ 20/Feb/15 ]

Thanks for your report itsmejainh. The SERVER project is for reporting bugs or feature suggestions for the MongoDB server. For MongoDB-related support discussion please post on the mongodb-user group or Stack Overflow with the mongodb tag, where your question will reach a larger audience. A question like this involving more discussion would be best posted on the mongodb-user group.

Regards,
Ramón.

Generated at Thu Feb 08 03:44:03 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.