Skip to content

Commit f6504d3

Browse files
Use histogram
1 parent 939e6f0 commit f6504d3

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

packages/destination-actions/src/destinations/webhook-audiences/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ const destination: AudienceDestinationDefinition<Settings, AudienceSettings> = {
148148
for (const p of payload) {
149149
set.add(`${p.url} ${p.method} ${JSON.stringify(p.headers)}`)
150150
}
151-
statsClient?.incr('webhook.configurable_batch_keys.unique_keys', set.size, tags)
151+
statsClient?.histogram('webhook.configurable_batch_keys.unique_keys', set.size, tags)
152152
}
153153

154154
// Call the same performBatch function from the regular webhook destination

packages/destination-actions/src/destinations/webhook/__test__/webhook.test.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ export const baseWebhookTests = (def: DestinationDefinition<any>) => {
235235

236236
expect(responses.length).toBe(1)
237237
expect(responses[0].status).toBe(200)
238-
expect(statsClient.incr).toHaveBeenCalledWith(
238+
expect(statsClient.histogram).toHaveBeenCalledWith(
239239
'webhook.configurable_batch_keys.unique_keys',
240240
2,
241241
statsContext.tags

packages/destination-actions/src/destinations/webhook/send/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ const action: ActionDefinition<Settings, Payload> = {
7878
for (const p of payload) {
7979
set.add(`${p.url} ${p.method} ${JSON.stringify(p.headers)}`)
8080
}
81-
statsClient?.incr('webhook.configurable_batch_keys.unique_keys', set.size, tags)
81+
statsClient?.histogram('webhook.configurable_batch_keys.unique_keys', set.size, tags)
8282
}
8383

8484
try {

0 commit comments

Comments
 (0)