Phil Hale
Phil Hale

Reputation: 3491

Tools and techniques for effective use of feature toggles in .NET

I have read a lot about feature toggles but have no practical experience of using them. What tools and techniques do people recommend for effective management of feature toggles?

I imagine the simplest way would be to store toggles as true/false values in the web.config file as appSettings but this doesn't sound a particularly good method.

Ideally I would like any method of managing feature toggles to:

Upvotes: 11

Views: 2341

Answers (2)

CodesInChaos
CodesInChaos

Reputation: 108810

I'd just use a class with a number of boolean properties and deserialize the values from a config file.

Upvotes: 2

Phil Hale
Phil Hale

Reputation: 3491

One suggestion from a colleague is to store them in a .settings file. The advantage of this is that if you delete a toggle you get compiler errors anywhere the toggle has been used so you can be certain it's been completely removed from the code.

It's also possible to use some simple techniques to do feature toggling. It's not big or clever, but it's straight forward and it works.

UPDATE

Since asking this question I've had some more experience using feature toggles. I've looked at a few of the open source tools available and written about another simple database driven toggling mechanism I've used at work.

Upvotes: 3

Related Questions