Skip to content

Unnecessary count operations in Data Browser #2246

Closed
@dplewis

Description

@dplewis

New Issue Checklist

Issue Description

Count operations are very expensive and are run every time the data browser changes classes.

https://github.com/parse-community/parse-dashboard/blob/alpha/src/dashboard/Data/Browser/Browser.react.js#L176

Steps to reproduce

Inspect element on your browser and load the page. The count operations run for every class. Switching classes will also run count operations (easier to notice on classes with a lot of objects).

Actual Outcome

Count runs once the page loads and every change between classes.

Expected Outcome

Run count only once when the page loads

Environment

Dashboard

  • Parse Dashboard version: 4.1.4
  • Browser (Safari, Chrome, Firefox, Edge, etc.): Chrome
  • Browser version: 103.0.5060.134

Server

  • Parse Server version: 4.1.2
  • Operating system: Mac
  • Local or remote host (AWS, Azure, Google Cloud, Heroku, Digital Ocean, etc): local

Database

  • System (MongoDB or Postgres): Mongo
  • Database version: 4.2
  • Local or remote host (MongoDB Atlas, mLab, AWS, Azure, Google Cloud, etc): Atlas

Logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    type:featureNew feature or improvement of existing feature

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions