-
Notifications
You must be signed in to change notification settings - Fork 5
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
Manage ids across different mappings connected to the same database #21
Comments
In GitLab by @manuelma on Oct 1, 2018, 10:45 The next_id table is in place and works fine. Needs testing. One weakness is ids are incremented before the user commits their changes, so if they rollback instead we 'lose' a lot of ids. Do we care? |
In GitLab by @jkiviluo on Oct 2, 2018, 10:30 You mean there will be id numbers that have been skipped over and will not be used in the DB anymore? I wouldn't care as long as the max id is substantial. |
In GitLab by @manuelma on Oct 2, 2018, 10:48 Apparently the max in SQLite is 2^64, that is 1.84e19. So we have some room but also we can implement some logic so as not to skip ids. |
In GitLab by @jkiviluo on Oct 2, 2018, 14:54 In my opinion that's substantial. :) |
In GitLab by @manuelma on Jan 24, 2019, 16:07 This is done but needs unittesting. |
In GitLab by @manuelma on Sep 29, 2018, 15:26
There needs to be a way for a DiffDatabaseMapping to reserve ids, so that other processes don't steal them from it. An idea would be to create a table
next_id
that the DiffDatabaseMapping will keep updated. If the other process finds this table, it'll also use it and update it.The text was updated successfully, but these errors were encountered: