[COMPASS-5791] Compass collect actual document count when browser collection automatically. Created: 03/May/22  Updated: 28/Jun/23

Status: Open
Project: Compass
Component/s: Aggregation pipeline
Affects Version/s: 1.31.2
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: 아나 하리 Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

MacOS Catalina 10.15.7(19H2)


Story Points: 3

 Description   

Problem Statement/Rationale

Looks Compass collect actual document count when users browser collection.

Compass run following aggregate query. 

db.collection.aggregate( [{
    $group: {_id: null, count: { $count: { } } }
}] );

But this may scan full collection or index which takes a lot of time for huge collections. Also consume lots of computing resources.

I think this should not be automatically collected.

This should be either configurable option(or action button on GUI) or eliminated.

Steps to Reproduce

Login some mongodb cluster, click some collection on left bottom of GUI

Expected Results

Minimize system resource usage

Actual Results

Doing full collection full or full index scan to collection's document count (using aggregate command)

Additional Notes

Any additional information that may be useful to include.


Generated at Wed Feb 07 22:40:50 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.