Every day, we talk to teams that use feature flags to drive their modern software development process—simplifying deployments or providing much-needed flexibility to roll changes to groups of users and targets to implement progressive delivery. After the software release is complete and the user experience verified, the flag has served its purpose, and it’s time to delete it - first from the code, then from Harness. Once in a while, though, someone deletes a flag before removing it from the code.
Deleting a feature flag can result in the wrong values being served to your end customers, as Harness Feature Flags will fall back to the in-code default rule if it can’t find a flag configuration to serve. Having this happen in a production environment can enable or disable specific features that a product manager didn’t intend for the user base, creating an urgent issue needing resolution. Until now, when this happened, you’d have to create a new feature flag with a matching identifier to the deleted flag and recreate the flag-specific configuration. With the introduction of flag archiving into our feature flag management lifecycle, a user can just click restore flag.
How It Works for Development Teams
Harness makes archiving a flag through the normal flag management process easy.
In your Harness project, navigate to Feature Flags > Feature Flags.
Next to the flag you want to archive, select more options (︙), and then select Archive.
The Archive Flag confirmation screen appears next. If the flag you're archiving is a prerequisite to a second flag, you can select the second flag from this screen to remove the dependency, and then try archiving again.
If you're sure you want to archive the flag, type the name or ID of the flag in the field provided, and then select Archive.
Developers can restore this flag within 30 days, otherwise, the archived flag will be deleted.
More than a Feature Toggle
Developers change, update, and create code every day. At Harness, we are addressing developer toil across the entire software delivery lifecycle to decouple the code deployment from feature releases. Removing the burden of complex lifecycle flag management is a straightforward improvement this new feature provides.