SettingStoreAdapter chains a setting get operation, if current adapter cannot locate setting value, it will invoke next adapter until last one.
| 20 | // SettingStoreAdapter chains a setting get operation, if current adapter cannot locate setting value, |
| 21 | // it will invoke next adapter until last one. |
| 22 | type SettingStoreAdapter interface { |
| 23 | // Get a string setting from underlying store, if setting not found, default |
| 24 | // value will be used. |
| 25 | Get(ctx context.Context, name string, defaultVal any) any |
| 26 | } |
| 27 | |
| 28 | // NewDbSettingStore creates an adapter using DB setting store. Only string type value is supported. |
| 29 | func NewDbSettingStore(c inventory.SettingClient, next SettingStoreAdapter) SettingStoreAdapter { |
no outgoing calls
no test coverage detected