Skip to content

Conversation

@hoytak
Copy link
Collaborator

@hoytak hoytak commented Nov 15, 2025

This PR refactors the current configuration system built on configurable_constants!{} to instead use an explicit XetConfig struct defined in a new xet_config package and instantiated as part of the xet runtime. All of the config values that were previously configurable by environment variables have now been moved into this structure.

Each of the modules having config values here has a separate group that is loaded as part of the config.

On runtime start, environment variables are still checked in the same way as before, so this PR should largely be backwards compatible.

The previous configurable_constants!{} macro is now test_configurable_constants!{} and is meant for testing constants that can only be changed in debug mode for specific tests. This allows us to drop the release_fixed decorator.

In addition, high performance mode is handled by an explicit function on XetConfig, with_high_performance_mode(), that sets the defaults of some of the constants to the high performance values. This is called if high performance mode is enabled.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants