3 ms·
Is a service for feature flags, where feature flags are a software pattern in a way. If you want to learn more about it, have a look into this: https://martinfo
by brunoluiz 6y ago
Is a service for feature flags, where feature flags are a software pattern in a way. If you want to learn more about it, have a look into this: https://martinfowler.com/articles/feature-toggles.html https://martinfowler.com/articles/feature-toggles.html
In a nutshell, it allows developers to deploy new features but hide them based on a flag. Once it is ready to be released (example: product gave an ok, big announcement happened etc), then this feature just needs to be enabled through this flag. Now, this flag can be an environment variable, but for apps you will probably need a service, which the app always fetch the latest feature configs.
We use it here (although using Flaggio https://github.com/victorkt/flaggio https://github.com/victorkt/flaggio) and it is super useful for continuous delivery. And you can as well control features based on groups (example: show just for beta users) or hide features if some bug was discovered.
- marcus_holmes 6y agoI'm always curious about Feature Flags - I'd love to use them. But they only seem to work if the interface doesn't change. From the example you gave: function reticulateSplines(){ if( featureIsEnabled("use-new-SR-algorithm") ){ return enhancedSplineReticulation(); }else{ return oldFashionedSplineReticulation(); } } All well and good as long as the enhancedSplineReticulation returns the exact same structure that the old one did. If it doesn't, then a bunch of code that handles the new reticulated splines also needs to be behind a flag (because the structure changed). And that could mean a chunk of UI needs to be duplicated behind a flag because it changed, and so on. How do you use feature flags when the features aren't just trivial changes to methodology, but affect multiple parts of the system?
- markn951 6y agoCheck the flags in multiple parts of the system, or duplicate some logic and have two completely self-contained components, one with the new pieces and one untouched.
- marcus_holmes 6y agoYeah, I suppose so. But how do you deal with multiple feature flags implemented on the same piece of the system? How do you create discrete components when you have three or more features intersecting on that component? And presumably there's a proliferation of test cases, too (because you'd need to test that everything works with all combinations of features A,B,C,D implemented)? How much of this gets cleaned up afterwards? When the feature is fully rolled out, how do you resist the pressure to move on to another feature and leave the flags implemented rather than clean it all up and remove the old code?