A checkout rewrite sat inside Friday's production build with its entry point switched off. The code had shipped; the behavior had not. On Monday one configuration change opened it for a single region, then for everyone. That gap between deployment and release is the reason feature flags exist.
Deployment ends before the decision
Pete Hodgson's article on martinfowler.com, published 2017-10-09, defines a release toggle as a device for trunk-based development and continuous delivery. Incomplete and untested paths can land as latent code, present in production but never reached. The article calls this the most common way to separate feature release from code deployment. The mechanism is deliberately plain. A condition near the entry point chooses the branch, configuration supplies the condition, and the build artifact is identical either way.
What changes is who holds the decision. Deployment becomes an engineering event with a fixed time. Release becomes a choice that can move to a later window, made when the signal the team trusts finally appears. Splitting the two removes the requirement that every line of code be finished on the same day it goes live.
Lifetimes differ by orders of magnitude
Hodgson sorts toggles along two axes: how long they survive and how dynamic the switching decision is. The durations in the article describe that classification; none of them is a measurement from a platform. Release toggles are transitional and, in the article's words, should generally not stick around much longer than a week or two. Experiment toggles stay long enough to reach statistical significance, which may take hours or weeks. Permissioning toggles can last multiple years in a premium scenario and are re-evaluated constantly because the answer depends on who is asking. Ops toggles sit on a separate line. Most are short-lived and should be retired once confidence in the running system arrives; a few become long-lived kill switches, manually managed circuit breakers that must be reconfigured extremely quickly, since shipping a new release to flip them defeats their purpose.
| Toggle role | Lifetime described in the source | Reason to retire it |
|---|---|---|
| Release | Roughly a week or two, as a rule of thumb | The feature is open and the gate has served its purpose |
| Experiment | Hours or weeks, until significance | The hypothesis has been settled |
| Permissioning | Years in a premium scenario | Entitlement rules changed or the product line ended |
| Operational | Short, with a few permanent kill switches | Confidence arrived, or the emergency control is removed |
The cost arrives after launch
Hodgson names the price directly. Toggles multiply quickly, add conditional logic or an abstraction, and bring a significant testing burden. The advice is to handle them as inventory with a carrying cost: keep a cleanup backlog, give flags expiration dates, plant time bombs that fail when a deadline passes, and put a cap on the quantity. The wording matters. The article uses the terms carrying cost and inventory. Technical debt is a later summary and does not appear in its text.
Fowler's bliki page, dated 2010-10-29 with a 2023-07 footnote, makes the retirement step concrete. Once the feature is stable in production, the release flag should go, both the definition in configuration and the code that reads it. What remains accumulates into what the page calls a pile of toggles that nobody can remember how to use. The same page retells a story about a Linux kernel rebuilt because of too many command-line switches. Fowler introduces it as something heard rather than a measured case, so it works as a memorable warning and little else.
Testing combinations without exhausting them
Fowler offers a restrained test plan for release flags. Run the combination expected in the next release, with the flags due to open switched on, and run the state with all flags on. Toggle checks belong at the entry point. If creating, maintaining or removing a flag takes noticeable effort, the code has too many toggle points.
The LaunchDarkly guides, vendor material checked on 2026-11-26 with no static version, call the demand to test every combination the combinatorial explosion myth. Their recommended scenarios are the current production state, the upcoming production state, the fallback value, and states that failed before or carry unusual importance. Integration and end-to-end suites need a fixed flag configuration: values read from a file, a dedicated test environment, or the offline mode of Relay Proxy. Testers sharing one environment overwrite each other's configuration. These recommendations belong to a specific product and deserve to be read with that label.
The same vendor guide splits flags into temporary and permanent. Release, experiment and migration flags are temporary and should be archived once the goal is met; kill switches, operational and entitlement flags usually stay. It discourages flags for values that are static or rarely change, and for configuration that would block startup if disabled, such as a database hostname or an API URL. The guide places flags outside configuration management and outside secret management.
Two classification schemes circulate at once. Hodgson's release, experiment, permissioning and ops roles and the vendor's release, kill switch, experiment, entitlement and operational categories come from different sources and do not line up one to one. Treating them as a single taxonomy erases the distinction each author drew.
Every decision deserves an expiry date
A flag is useful only while the choice is still open. After that it becomes a branch every future reader has to understand. Writing the removal date into the description at creation time costs one line; finding the owner of a forgotten flag years later costs considerably more.
Cross Mini App keeps flags around the shared runtime as one more thing to retire on time.