Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Checkpoint iteration strategy failing in simultaneous pull-push scenario. #5843

Open
utkarshtopinkatti051 opened this issue Apr 2, 2024 · 3 comments

Comments

@utkarshtopinkatti051
Copy link

utkarshtopinkatti051 commented Apr 2, 2024

Have you found a bug?

Yes! The checkpoint iteration strategy uses the "updatedAt" field of the latest pulled document, but in this case, the collection doesn't have this document. It's strange that this record is not logged in the conflict resolver either. Here are the steps to reproduce the issue:

  1. A document was updated on the server side while the client was in offline mode.
  2. The client updated the document while offline.
  3. The client came back online.
  4. The pull query was executed first, followed by the push query.
  5. The checkpoint iteration used the "updatedAt" field of the latest pulled document, but the collection still had the older document instead of the latest pulled document.

References

I further checked previously raised issue around this area but not sure if this is related to the one, I am facing.
#5571 (comment)

Rxdb Version used

-v15.16.0

@pubkey
Copy link
Owner

pubkey commented Apr 2, 2024

Please make a PR with a test case, then I can fix that otherwise I cannot start working on it.

Copy link

stale bot commented Apr 29, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed soon. If you still have a problem, make a PR with a test case or to prove that you have tried to fix the problem. Notice that only bugs in the rxdb premium plugins are ensured to be fixed by the maintainer. Everything else is expected to be fixed by the community, likely you must fix it by yourself.

@stale stale bot added the stale label Apr 29, 2024
@pubkey
Copy link
Owner

pubkey commented May 12, 2024

@utkarshtopinkatti051 I am still interested in this. Can you make a PR with a failing test case to reproduce the problem?

@stale stale bot removed the stale label May 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants