Integrations use cases
Read time: 6 minutes
Last edited: Sep 18, 2024
Overview
This guide provides three example use cases showing how LaunchDarkly integrations can solve common problems within your organization. In addition to these, LaunchDarkly provides integrations with integrated development environment (IDE) connectors, workflow management tools, and more. To learn about all of our available integrations, read Integrations.
Three common use cases are:
- Keeping your teams informed about flag changes
- Diagnosing flag-related performance changes
- Automating application performance management
For an overview of available LaunchDarkly integrations, read About LaunchDarkly integrations.
Keep your teams informed about flag changes
Keeping different teams within your organization informed about the various projects and services you are building, releasing, and supporting can be a challenge. The more projects your organization manages, the harder it is for multiple teams to track what everyone is working on.
LaunchDarkly chat integrations help solve this problem by keeping your teams informed about flag changes in targeted chat channels.
Prerequisites
To use this guide, you need:
- A chat integration: either Microsoft Teams or Slack
Chat integrations
When someone updates a flag, either directly in LaunchDarkly or through the chat app, the app can send a notification of the change to any channel subscribed to updates for that flag. You can use filters to send notifications to a project channel about a specific subset of flags.
For example, imagine you're working on a project to update the checkout flow on your website. You can set up project-specific notifications in a project-specific Slack channel.
Here's how:
- In LaunchDarkly, tag all your flags related to the project with
checkout_flow
. - In Slack, create a channel called
#new-checkout-flow
. - Enter
/launchdarkly subscribe [-t <checkout_flow>]
in the text bar.
- Click Send. A confirmation message appears.
- Click Add subscription to channel or adjust your subscription if needed. To learn more about adjusting subscriptions in Slack, read Manage subscriptions.
Now, any time a change is made to a flag with the checkout_flow
tag in LaunchDarkly, LaunchDarkly sends a notification to the #new-checkout-flow
Slack channel.
You can set up multiple chat integrations with different policy filters. For example, in a general channel, you may want to send updates about all flag changes as a review method.
Using required approvals to sign off on any flag changes before they're made is one way to prevent mistakes. But you may decide that requiring an approval for every single flag change unnecessarily delays deployment. Instead, you can allow flag changes by default and use a #feature-flag-review
chat channel to quickly review all flag changes as they are made.
You can create a similar process in other apps. To learn how to set up chat integrations with policy filters in Microsoft Teams, read Setting up the Microsoft Teams integration.
Diagnose flag-related performance changes
You’re reviewing charts in your application performance management (APM) tool and notice an unusual result. Could the problem be related to a flag change? You can use APM tool integrations to help diagnose if performance changes or issues in your app are related to feature flag changes.
Prerequisites
To use this guide, you need an APM tool event integration set up with one of the following:
- AppDynamics
- Datadog
- Dynatrace
- Elastic (ELK) Stack
- Honeycomb
- New Relic One
- Splunk
- Splunk Observability Cloud
APM tool integrations
Imagine you monitor your app performance using New Relic One. You notice on the Errors dashboard that you're receiving an increase in HTTP response code 500 errors.
This is cause for concern. Your team recently started a database migration, and you wonder if the increase in errors is related. Luckily, you planned for potential issues by putting the migration behind a feature flag, and are rolling it out to your end users incrementally rather than all at once.
Flag change events in your production environment create new deployment events in New Relic One, which let you understand the impact of specific flag changes. To find out if the 500 errors started when you turned on the migration flag, you navigate to your Deployments page. As you suspected, the errors began around the time your team toggled on the flag. Your error rate jumped from less than 1% to almost 7%.
You toggle targeting off until the issues can be addressed, and your HTTP response code errors return to their normal levels.
You can set up multiple APM tool integrations with different policy filters to monitor different aspects of your app performance.
Automate application performance management
Imagine you're releasing a new feature in your app. You have thoroughly tested in production using feature flags, but you know there is the possibility the change could have a negative impact on your application’s performance.
In our Diagnose flag-related performance changes example, you were able to confirm that HTTP response code 500 errors appeared unexpectedly as a result of turning on a flag. To mitigate that, you disabled the feature until you could put a fix in place. But what if you didn't want to manually monitor your app performance, or the error spike happened in the middle of the night?
You can use flag triggers to set up automation that disables a flag when a chosen metric goes above a certain threshold. That way, negative effects from the flag change are mitigated before you can address the root cause.
Prerequisites
To use this guide, you need an APM tool flag trigger integration set up with one of the following:
Flag triggers
In this example, you will automate the process of turning off the flag as described in Diagnose flag-related performance changes using New Relic One. Automating a flag toggle change when a certain limit is breached is known as a "circuit breaker."
For detailed documentation on creating New Relic One notification channels and policies, read New Relic's Add or remove notification channels and Create an alert policy.
Here is how to set up a circuit breaker to toggle a flag's targeting off when your HTTP errors reach a 2% threshold in New Relic One:
- Create a New Relic One flag trigger on your feature flag that toggles targeting to
off
.
- Click Save trigger. A confirmation appears with a unique trigger URL.
- Copy and save the unique trigger URL. You will need this URL to complete the next step. After you leave this page, the trigger URL will be obscured and you will not be able to view it again.
- In New Relic One, configure a notification channel to use the LaunchDarkly trigger you just created. Enter the unique trigger URL into the "Base Url" field.
- Create a policy and add alert conditions to the policy.
- Connect the webhook notification channel to the policy.
Now when your HTTP response code 500 errors rise above a 2% threshold, New Relic One uses the flag trigger to toggle the flag's targeting off.
To learn more about webhook notification channels, read Connect a flag trigger to New Relic One.
Conclusion
This guide demonstrates just a few ways LaunchDarkly integrations can solve common problems within your organization. To learn more about all of our integrations available, read Integrations.
Your 14-day trial begins as soon as you sign up. Get started in minutes using the in-app Quickstart. You'll discover how easy it is to release, monitor, and optimize your software.
Want to try it out? Start a trial.