This PR refactors setting stuff in order to enable checkpoint manager to recover setting values. In addition, added some convenient functions.
- Fix Points of SettingsManager
Change All set functions to non-static, and move all set/get functions to public.
Add txn argument into set functions in order that a caller of set functions can manage a necessary transaction by itself.
Add set_default argument into set functions. If this flag argument is true, then the default value is updated in addition to updating the setting value.
Add Reset public function to reset the setting value to default value.
Add UpdateSettingListFromCatalog() public function to update setting values in the manager from catalog for checkpoints.
Add/Modify two catalog management private functions: InsertCatalog(), UpdateCatalog().
- Fix Points of SettingsCatalog
Add SettingsCatalogEntry class to acquire all setting information from catalog
Add GetSettingsCatalogEntry() and GetSettingsCatalogEntries() functions.
*These function names are temporary. The permanent names depend on discussion in PR #1414.
Delete other get functions.
Add UpdateSettingValue() function to update a setting value and a default value.
Coverage decreased (-0.1%) to 76.39% when pulling ebc71addd5bf95063e914335e2c2348e9fd89f7e on ksaito7:settings_refactor into 898219f9fe6e1d2b6901ea3797caac5c93850213 on cmu-db:master.
This last commit isn't related to this PR directly, but I did it because a part of index names of constraints were weird. (related to #1415 we worked for last time)
This PR refactors setting stuff in order to enable checkpoint manager to recover setting values. In addition, added some convenient functions.
- Fix Points of SettingsManager
txn
argument into set functions in order that a caller of set functions can manage a necessary transaction by itself.set_default
argument into set functions. If this flag argument is true, then the default value is updated in addition to updating the setting value.Reset
public function to reset the setting value to default value.UpdateSettingListFromCatalog()
public function to update setting values in the manager from catalog for checkpoints.InsertCatalog()
,UpdateCatalog()
.- Fix Points of SettingsCatalog
SettingsCatalogEntry
class to acquire all setting information from catalogGetSettingsCatalogEntry()
andGetSettingsCatalogEntries()
functions. *These function names are temporary. The permanent names depend on discussion in PR #1414.UpdateSettingValue()
function to update a setting value and a default value.- Related Issues