Skip to content

Commit

Permalink
Merge pull request #282 from launchdarkly-labs/cko_2025
Browse files Browse the repository at this point in the history
update
  • Loading branch information
ahmedhqadri authored Feb 8, 2025
2 parents 27818ff + e72b427 commit 96ab6ae
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,13 +80,13 @@ const GuardedReleaseGenerator = ({ flagKey, title }) => {
errorMetric = "recent-trades-db-errors";
latencyMetric = "recent-trades-db-latency";
latency = isEnabled ? randomLatency(100, 130) : randomLatency(120, 140);
errorRate = isEnabled ? 75 : 25;
errorRate = isEnabled ? 15 : 15;
}

client.track(latencyMetric, undefined, latency);

await client.flush();
if (Math.random() < errorRate) {
if (Math.random() * 100 < errorRate) {
client.track(errorMetric);
await client.flush();
}
Expand Down

0 comments on commit 96ab6ae

Please sign in to comment.