Settings Rework: Move many more settings to the generic settings and extend functionality/speed up retrieval#20508
Merged
Mytherin merged 61 commits intoduckdb:v1.5-variegatafrom Jan 14, 2026
Merged
Conversation
…ly to avoid turning a default value into a duckdb::Value
…al by defining the "scope" instead of the "default_scope"
the pragma itself has no added value
evertlammerts
added a commit
to duckdb/duckdb-python
that referenced
this pull request
Jan 16, 2026
Fixes related to: * duckdb/duckdb#20564 * duckdb/duckdb#20508 * duckdb/duckdb#20547
Merged
staticlibs
added a commit
to staticlibs/duckdb-mysql
that referenced
this pull request
Jan 17, 2026
This PR updates submodules to latest available and adds minor adjustments (required by duckdb/duckdb#20508 and other changes).
staticlibs
added a commit
to staticlibs/duckdb-mysql
that referenced
this pull request
Jan 17, 2026
This PR updates submodules to latest available and adds minor adjustments (required by duckdb/duckdb#20508 and other changes).
staticlibs
added a commit
to staticlibs/duckdb-postgres
that referenced
this pull request
Jan 18, 2026
This PR updates submodules and adds a number of minor changes: - update `duckdb` submodule to the latest `v1.5-variegata` - update `extension-ci-tools` submodule to the latest `main` - update `MainDistributionPipeline.yml` to the same versions of the engine and CI tools as above - update `Linux.yml` to set `LOCAL_EXTENSION_REPO` env var that is now (after some recent `unittest` chage) is required to run tests with extensions that are not statically linked (otherwise `require postgres_scanner` fails) - apply patch `getdatainternal.patch` from the engine repo - add a change to `postgres_storage.cpp` to accomodate to changes added in duckdb/duckdb#20508 - update `attach_types.test` that started failing due to duckdb/duckdb#20361 change PS: due to changes required for duckdb/duckdb#20508 it is suggested to add `v1.4-andium` branch to this repo (on a current `main`).
staticlibs
added a commit
to duckdb/duckdb-mysql
that referenced
this pull request
Jan 18, 2026
This PR updates submodules to latest available and adds minor adjustments (required by duckdb/duckdb#20508 and other changes).
d-justen
pushed a commit
to d-justen/duckdb
that referenced
this pull request
Jan 19, 2026
…extend functionality/speed up retrieval (duckdb#20508) Follow-up from duckdb#18447 The previous PR introduced a concept of "generic settings" - which are settings that don't need to exist as variables in the code as before. The advantages of these settings are as follows: * Generic settings can be set both globally and locally, instead of having a fixed "position" of where they are assigned * Accessing these settings does not rely on direct variable access - as a result accessing / modifying these settings can be made thread-safe, etc * These settings are better aligned with extension-provided settings, since they cannot have non-generic variables in the DBConfig and ClientConfig * Less code needs to be generated to support these settings The idea behind these settings is that we migrate all settings to these generic settings as much as possible (and ideally we migrate all of them). The main change made in this PR is to migrate many more settings to this framework. Furthermore, this PR improves generic settings in a number of ways: * Accessing generic settings is now done through a `Settings` class instead of through the `DBConfig`. This is less verbose and requires only including the `settings.hpp` file instead of requiring an include of both the `DBConfig` and `settings.hpp`. ```cpp Settings::Get< EnableExternalAccessSetting>(context); ``` * Add support for having generic settings that can **only** be set globally or **only** be set locally. This is done through providing a `scope`. The following options are now possible: ```py # can only be set globally "scope": "global" # can only be set locally "scope": "local" # can be set both locally and globally, defaults to global if not specified explicitly "default_scope": "global" # can be set both locally and globally, defaults to local if not specified explicitly "default_scope": "local" ``` * Improve performance of accessing generic settings by avoiding `Value` casts. In a follow-up PR I'm working on further improving performance.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Follow-up from #18447
The previous PR introduced a concept of "generic settings" - which are settings that don't need to exist as variables in the code as before. The advantages of these settings are as follows:
The idea behind these settings is that we migrate all settings to these generic settings as much as possible (and ideally we migrate all of them).
The main change made in this PR is to migrate many more settings to this framework. Furthermore, this PR improves generic settings in a number of ways:
Settingsclass instead of through theDBConfig. This is less verbose and requires only including thesettings.hppfile instead of requiring an include of both theDBConfigandsettings.hpp.scope. The following options are now possible:Valuecasts. In a follow-up PR I'm working on further improving performance.