-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Fix order of SQLite PRAGMAS to allow configurable page_size #5140
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #5140 +/- ##
=======================================
Coverage 76.2% 76.2%
=======================================
Files 760 760
Lines 61550 61550
Branches 8123 8122 -1
=======================================
+ Hits 46884 46888 +4
+ Misses 14666 14662 -4
|
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.
LGTM
For readers of this PR:
FWIW |
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.
Important to move these pragmas first so that PRAGMA page_size
is executed before PRAGMA journal_mode
(which accesses the database and commits the page_size)
High Level Overview of Change
Fixed the order of application of pragmas when opening SQLite connection. Due to specific pragmas set with
commonPragmas
, it looks like a page gets allocated in the DB file BEFOREpage_size
is set, thus locking the page_size to default value 4096.Context of Change
This issue has no effect before #5135 is merged.
Type of Change
Test Plan