[COMPASS-3269] Poor performance when using Views in Compass Created: 19/Nov/18 Updated: 29/Oct/23 Resolved: 21/Dec/18 |
|
| Status: | Closed |
| Project: | Compass |
| Component/s: | Compass |
| Affects Version/s: | None |
| Fix Version/s: | 1.18.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Ivan Grigolon | Assignee: | Durran Jordan |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
||||||||
| Issue Links: |
|
||||||||
| Sprint: | Iteration Unagi | ||||||||
| Description |
|
A user is reporting a timeout problem in Compass when clicking on a View where the underlying collection has around 15.2m documents and a total size of 517.2GB. Document's average size is 35.6KB. I have been able to reproduce the same problem in my testing environment. The problem only appears when the original collection is fairly large, (in my testing I could only generate the problem when I had 5M documents in it) and the View is not using a $match stage to filter out the content. Compass produce a timeout visible in the UI (see attachment)
When the view is clicked in the UI, an aggregation pipeline is used to count the number of documents on the underlying collections. When the time to run this count command goes above a threshold that appears to be around 6 minutes, Compass timeout the operation. The following count operation is visible in the log:
I believe this is an undesirable behaviour because: |
| Comments |
| Comment by Githook User [ 21/Dec/18 ] |
|
Author: {'username': 'durran', 'email': 'durran@gmail.com', 'name': 'Durran Jordan'}Message: |
| Comment by Githook User [ 21/Dec/18 ] |
|
Author: {'username': 'durran', 'email': 'durran@gmail.com', 'name': 'Durran Jordan'}Message: |
| Comment by Githook User [ 13/Dec/18 ] |
|
Author: {'username': 'durran', 'email': 'durran@gmail.com', 'name': 'Durran Jordan'}Message: |
| Comment by Githook User [ 13/Dec/18 ] |
|
Author: {'username': 'durran', 'email': 'durran@gmail.com', 'name': 'Durran Jordan'}Message: |