Datadog

How Bucket integrates with Datadog to catch regressions on new feature releases

With the Datadog integration, you can enrich your RUM data with feature flag data. This will enable you to catch regressions on new feature releases.

Get available features from Bucket

In this example, we're using the React SDK:

import { datadogRum } from "@datadog/browser-rum";
import { useClient } from "@bucketco/react-sdk";

// Component to enhnance datadog RUM with flag checks
function DatadogIntegration() {
  const client = useClient();
  useEffect(() => {
    return client?.on("check", (check) => {
      datadogRum.addFeatureFlagEvaluation(check.key, check.value);
    });
  }, [client]);
  return null;
}

Add the component inside the BucketProvider:

function App() {
  return (
    <BucketProvider>
      <DatadogIntegration /> // Add the component inside the <BucketProvider>
      {children}
    </BucketProvider>
  )
}

Which will look like this on Datadog:

Last updated

Was this helpful?