Exploring switches
The basic idea of a feature flag is simple and as we saw in Chapter 3, Basics of LaunchDarkly and Feature Management, they are easy to implement too. This simple yet powerful encapsulation has been the basis of both rollouts and experiments and ultimately, it has been about being able to enable or disable a feature before exposing it to all customers. This might have been to assess that either a technical hypothesis or business hypothesis is correct. By enabling a feature on the production environment and getting customers to interact with the new implementation, there is the opportunity to gain insight and validate an idea. Once proved successful, the feature can be rolled out to all customers. The feature flag encapsulation is then removed so that the new code is the only code that will be executed.
However, with the ability to turn on and off components within the system, there are scenarios where this ability to manage features becomes valuable permanently...