The Job method get_detailed_job_record_count() is designed to run only when the records of a Job are altered, and stores this information in job_details:
This was to prevent recalculating this every time the Job is viewed. However, in a situation where this value is not pre-calculated, it can be very slow to count when there are 1-2m+ records in Mongo.
The Job method
get_detailed_job_record_count()
is designed to run only when the records of a Job are altered, and stores this information injob_details
:This was to prevent recalculating this every time the Job is viewed. However, in a situation where this value is not pre-calculated, it can be very slow to count when there are 1-2m+ records in Mongo.