Feature Flags user metrics
Problem to solve
Visibility into how many times a feature toggle evaluated to enabled in a given time period.
Intended users
Developers/Release managers that want to monitor the feature toggles for analytics purposes Developers that want to keep track of undefined feature flags
Further details
Included in the unleash library
When you enable a feature for a small group of users it is nice to know how many users actually get exposed to it. This is why we added metrics to Unleash 2.0. The SDK will locally collect metrics in the background and regularly share this information with the Unleash API. The API then aggregates the metrics from all clients and calculates how many times a feature toggle evaluated to enabled in a given time period.
When implementing the metrics feature we discovered that this was a nice way to display which toggles are actually in use in an application. It even made it possible to show feature toggles being used in the client code which is not defined in the Unleash API. Showing undefined toggles used in client applications makes it easier to discover feature toggles not defined in Unleash UI. This can happen when a developer starts using a new feature toggle but has not defined it in Unleash UI yet. The undefined feature toggle is also a clickable link to make it easy to define it in Unleash.
Proposal
Use the unleash
API to collect metrics and present to the user
POST: http://unleash.host.com/api/client/metrics
{ "appName": "appName", "instanceId": "instanceId", "bucket": { "start": "2016-11-03T07:16:43.572Z", "stop": "2016-11-03T07:16:53.572Z", "toggles": { "toggle-name-1": { "yes": 123, "no": 321 }, "toggle-name-2": { "yes": 111, "no": 0 } } } }
This requires UX, but the general idea would be to allow the user to insert a date range and select a feature flag and the metrics would be presented to him/her.
For the MVC we can set a default time range - last 30 days and not have this configurable.
Permissions and Security
Documentation
Testing
What does success look like, and how can we measure that?
What is the type of buyer?
Links / references
https://schibsted.com/blog/unleash-features-gradually/
This page may contain information related to upcoming products, features and functionality. It is important to note that the information presented is for informational purposes only, so please do not rely on the information for purchasing or planning purposes. Just like with all projects, the items mentioned on the page are subject to change or delay, and the development, release, and timing of any products, features, or functionality remain at the sole discretion of GitLab Inc.