Hacker News new | ask | show | jobs
by vijayer 536 days ago
Could you elaborate on "stop using feature flags"? How is that considered bad (as long as you clean them up when their purpose is done)?
1 comments

Feature flags are not 100% reliable. They tend to be booleans of two different values. We've had complications on the null path, e.g. we assumed all mobile use would be either from Android or iOS, but sometimes an Android device refuses to identify as Android.

The fallback has to be handled properly. We make sure the default is the one with least risk and have to audit this regularly to fit the current state of the product. Yes, they're tech debt, there's also management overhead for this, and they should be regularly cleaned up. There was a habit of using it as a hack for unprepared releases, so we put some bureaucracy to make sure it's properly thought out.

They're also a security risk; hackers can just send a false flag, so we have to consider whether this is safe.

A lot of the use of feature flags is because a customer asked for a certain feature. For these, it's usually better to just hardcode it to if (customer===A)