Allows setting of some pragma values through environment variables #3899
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Brief summary
Adds support for setting some whitelisted SQLite PRAGMA values through environment variables.
Which issue is fixed?
Fixes #3750
In-depth Description
A whitelist of allowed pragma settings is defined, which currently contains
mmap_size
,cache_size
, andtemp_store
.Users can set the values for those pragmas, by setting the environment variable
SQLITE_<UPPERCASE_PRAGMA_NAME>
(e.g. SQLITE_MMAP_SIZE) to the requested value.These helped the reporting user optimize their database, and could be used by us in the future to set reasonable default values.
How have you tested this?
Set up all the supported pragmas through the corresponding env variables.