다음을 통해 공유


Roll-Up Board widget extension supports feature flags

We shared our research of the implementation of the feature flags, using LaunchDarkly, with our VSTS extensions in a series of blog posts:

To validate our research, we implemented and deployed feature flags in our Roll-up Board widget extension. Explore the sample code here.

Why did we pick the Roll Up Board widget extension?

It’s a simple extension and we had a few applicable items on our backlogs. This extension was the best candidate for our firsts implementation of features flags.

What changed?

Enabled/Disabled the telemetry monitoring to Application Insights

Over time we found that telemetry was not always relevant. For example, extensions in the Canary ring do not need to be monitored. Teams usually ignored that telemetry as noise.

In another case, one of our extensions was collecting and sending too much telemetry. We incurred unnecessary cost and had to temporarily disable the telemetry.

With the feature flag we’re able to activate or deactivate the telemetry without the need to release an update for the extension. We simply flip a flag or add a rule in the LaunchDarkly portal. You can apply these rules to a VSTS account or a specific user account.

clip_image002

For each feature flag we specified the default rule [1] - all user and all VSTS account by default send telemetry. We add a specific rule to ignore telemetry from our sandbox VSTS account [2], and individual user, where needed.

When disabled, the extension displays a message in the F12 Debugger console.

clip_image004

See Building VSTS Extensions with feature flags for details.

Enable/disable the display logs traces in browser developer tools

When developing an application (here we are talking about a VSTS extension) we often generate a lot of traces to enable debugging and troubleshooting.

These traces are especially useful with a web application for the development team. For the user, however, the traces are disruptive and of no value.

We allow the user to choose whether or not to capture logs in the F12 Debugger console.

clip_image006

Unlike other widget configuration parameters, this setting applies only to the current user and not for all team project users. By default, we do now show the logs. The user must enable the feature to see them.

clip_image008

On the side of LaunchDarkly, this parameter is simple. We just configure the default value of the rule, as shown.

clip_image010

What about TFS On-Prem?

We are currently investigating constraints with TFS on-prem, for example certificates and connectivity. For the time being, the Roll-up Board widget extension does not support feature flags on TFS on-prem. If you updated the extension on TFS on-prem, the extension will default to telemetry=enabled and logs=disabled.

What’s next?

Encourage other extension teams to add support for feature flags and investigate A|B testing using LaunchDarkly.

THANKS REVIEWERS - Niel Zeeman, David V. Corbin, Edward Fry, Darren Rich