parse-community / parse-community/docs

Parse.Object.saveAll can result in duplicate objects

Open
#859 13 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

docs:sdk-js
Dominant language
SCSS
Stars
317
Forks
507
PR merge metrics
No merged PRs in 30d

Description

New Issue Checklist
Issue Description

this issue has been specifically created to reference in this PR

Parse.Object.saveAll uses the /batch endpoint

if you have a large batch of large objects that are being saved via saveAll, and the network quality is very slow, it can happen that the initial request times out, and will therefore be automatically retried. However, some of the objects in the first batch may have already been successfully saved - but then the second retry would result in duplicate objects being created.

Steps to reproduce

Watch this Loom

Actual Outcome

duplicate objects created

Expected Outcome

no duplicate objects

Environment

JS SDK used in web client, over spotty networks

Server

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

Database

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

Client

  • Parse JS SDK version: latest
Logs

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with Parse.Object.saveAll and its /batch requests, then review the referenced Parse JS SDK pull request #1432 and the linked reproduction video. Done means retries on slow networks no longer create duplicate objects; the issue names no source files or tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, mongodb
Domain
api, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.