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

How to clean close a DB? #6142

Closed
NN-Binary opened this issue Jun 24, 2024 · 2 comments
Closed

How to clean close a DB? #6142

NN-Binary opened this issue Jun 24, 2024 · 2 comments
Labels

Comments

@NN-Binary
Copy link

When my program crash, I want to make sure all entries have been written, how do I "clean close" the Database and ensure all ongoing operations are done?

@pubkey
Copy link
Owner

pubkey commented Jun 26, 2024

This should be done automatically when you call .destroy()
To be extra sure you can await myDatabase.requestIdlePromise() which awaits the 100% idleness of the database.

Copy link

stale bot commented Jul 3, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed soon. Please update it or it may be closed to keep our repository organized. The best way is to add some more information or make a pull request with a test case. Also you might get help in fixing it at the RxDB Community Chat If you know you will continue working on this, just write any message to the issue (like "ping") to remove the stale tag.

@stale stale bot added the stale label Jul 3, 2024
@pubkey pubkey closed this as completed Jul 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants