jason-roberts / FeatureToggle

Simple, reliable feature toggles in .NET
http://dontcodetired.com/blog/?tag=/featuretoggle
Apache License 2.0
689 stars 111 forks source link

Allow feature to be set in code.. #107

Closed waynebrantley closed 8 years ago

waynebrantley commented 8 years ago

Change IFeatureToggle to have a get;set; This way the value can be read and written to. The writing my actually change the real setting, or it may just change the value in memory. So, for the SimpleFeatureToggle, it would read the value from the app settings as normal - only when first created - after that it would cache the value. That cached value can then be changed by code. Optionally a SimplePersistanceFeatureToggle may know how to write the value back to where it came from.

nlunn commented 8 years ago

get;set; on the toggle itself. That could be an idea. Another idea is to have the toggles read from a file or configuration into the memory. And in the memory you could manipulate the values through the provider?

waynebrantley commented 8 years ago

yes, that is what I was saying....you could have a get/set that was either persistent or non-persistent (writes the value back or not)

jason-roberts commented 8 years ago

duplicate of https://github.com/jason-roberts/FeatureToggle/issues/71