Skip to content

Data browser does not cancel obsolete long-loading request on sorting field change #2820

@mtrezza

Description

@mtrezza

New Issue Checklist

Issue Description

A long-loading request is not cancelled when changing the sorting field in the data browser. This causes the result of the long-loading request overwriting the result of the currently displayed data, while the field sorting indicator still shows the current sorting.

This is similar to #2671, it may be a separate issue or that the bug was not fixed completely.

Steps to reproduce

  1. Navigate to data browser.
  2. In a class with many objects where fieldA is an indexed field and fieldB is a non-indexed field.
  3. Click on header cell to sort by fieldB, then immediately on header cell to sort by fieldA.
  4. The results sorted by fieldA are displayed immediately.
  5. When the long-loading request sorted by fieldB finished, it will overwrite the results in the data browser while the header row still shows sorted by fieldA.

Expected Outcome

The long-longing request sorted by fieldB should be cancelled.

If possible, not only should the results not be displayed, but the HTTP request should be cancelled, so the server knows that the client doesn't need the response anymore and avoids sending the response unnecessarily. This doesn't require any changes in Parse Server, it's managed by the underlying HTTP library on the server side.

Environment

Dashboard

  • Parse Dashboard version: 7.2.0-alpha.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    state:releasedReleased as stable versionstate:released-alphaReleased as alpha versiontype:bugImpaired feature or lacking behavior that is likely assumed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions