Skip to content

Commit

Permalink
feat: log about dollar set usage in events (#22769)
Browse files Browse the repository at this point in the history
  • Loading branch information
tiina303 authored Jun 11, 2024
1 parent fda2156 commit 2b40181
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions plugin-server/src/utils/event.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
PostIngestionEvent,
RawClickHouseEvent,
} from '../types'
import { status } from '../utils/status'
import { chainToElements } from './db/elements-chain'
import { personInitialAndUTMProperties, sanitizeString } from './db/utils'
import {
Expand Down Expand Up @@ -256,6 +257,12 @@ export function formPipelineEvent(message: Message): PipelineEvent {
'$unset' in combinedEvent.properties)
) {
setUsageInNonPersonEventsCounter.inc()
if (Math.random() < 0.001) {
status.info('👀', 'Found $set usage in non-person event', {
event: combinedEvent.event,
team_id: combinedEvent.team_id,
})
}
}

const event: PipelineEvent = normalizeEvent({
Expand Down

0 comments on commit 2b40181

Please sign in to comment.