-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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 k/v store for repo settings #22500
Conversation
@delvh I think I did what you want. Please review again. |
Before we heavily start using our new user/repo/system setting tables, we should evaluate if the current database design is suitable. Currently we use something like
If we add a setting with the key This stackoverflow thread shows different ideas of how a settings system may be better designed. Additionally I would vote for different value type columns. At the moment we encode everything into strings. It may be beneficial to store values with the correct type: int(/bool) -> int, string/json -> string, ... |
I have tried that design. But from another view of a database maintainer, it's not easy to find the value if we know the setting key and change it in the database directly. Maybe it's a smart database's responsibility to reduce storage space for duplicated keys. @delvh done. |
I can see that repo has "unit" config, then why do we need this? |
Not all configuration belongs to a unit? |
For example? |
Closed as currently most repository level configuration could be stored in repo_unit table. |
replace #19400
credit @techknowlogick