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

Merge contents of SQLite WAL file into main database file on sync completion #1128

Merged
merged 3 commits into from
Nov 5, 2020

Conversation

abraunegg
Copy link
Owner

  • When using WAL and SHM files, certain thresholds are used to automatically determine when WAL and SHM data is committed to the main database file. If these thresholds are not met, the data is not written. Before terminating the program, commit the data, and at the end of each monitor loop, commit the data

* When using WAL and SHM files, certain thresholds are used to automatically determine when WAL and SHM data is committed to the main database file. If these thresholds are not met, the data is not written. Before terminating the program, commit the data, and at the end of each monitor loop, commit the data
@abraunegg abraunegg added this to the v2.4.7 milestone Nov 5, 2020
@abraunegg abraunegg requested a review from norbusan November 5, 2020 22:07
@abraunegg
Copy link
Owner Author

@norbusan
This is a potential fix for #893 as well, as in my testing, at the end of the monitor loop, the WAL file shrinks and memory is reclaimed.

@abraunegg abraunegg changed the title Merge contents of SQLite 3.7 WAL file into main database file Merge contents of SQLite WAL file into main database file on sync completion Nov 5, 2020
* Only try and write data to DB file and destroy variable if it was set to begin with
* destroy 'onedrive' variable rather than set to null
Copy link
Collaborator

@norbusan norbusan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very good idea!!!

@abraunegg abraunegg merged commit 57d6753 into master Nov 5, 2020
@abraunegg abraunegg deleted the fix-db-wal-no-merge branch November 5, 2020 23:28
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked and limited conversation to collaborators May 27, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants