-
Notifications
You must be signed in to change notification settings - Fork 571
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
Add deflate and inflate of panel content, changed gc chance from 1% t… #1022
Conversation
…o 10%, added 10% chance to vacuum when sqlite is used, added pragma commands for optimalization when using sqlite
$conn->execute('VACUUM;'); | ||
$conn->execute(' | ||
PRAGMA auto_vacuum = FULL; | ||
PRAGMA journal_mode = OFF; | ||
PRAGMA synchronous = OFF; | ||
PRAGMA foreign_keys = OFF; | ||
PRAGMA temp_store = MEMORY; | ||
PRAGMA automatic_index = OFF; | ||
'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this only happen if the GC is going to occur?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is not needed to run everytime, so it is run when gc is ran
PRAGMA automatic_index = OFF; | ||
'); | ||
|
||
if (!$this->shouldGcVacuum()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we've already passed the rand to do a GC why do we need another rand to do vacuum?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So rows are cleared more frequently, but the slow vacuum should be ran only 1% of requests (I made the check to own functions for static analysis tools and if we want to tweak the chance)
…te for content loaded from resource
Any other issues with this? |
We can't rely on this file being used. Instead we can log errors and let the application developer take care of removing their database file. Refs #1022
…o 10%, added 10% chance to vacuum when sqlite is used, added pragma commands for optimalization when using sqlite
#1021