posthog - is "Filter Out Plugin" drops events before or after they are added to the db?

123 Views Asked by At

i dont want some of my events going into posthog due to security . i thought using the "Filter Out Plugin" .

the question is: how does the plugin work? couldnt find spefici info about it . is it like a middleware that drops the events before they are added to the db ? or after ?

thnx

1

There are 1 best solutions below

0
On

The filter out app runs in the Posthog app/plugin server.

That means any events filtered by it are filtered before they are stored in the database. But those events will have passed through API code and a Kafka topic.

The plugin server is similar to a functions-as-a-service platform. It reacts to each event ingested. The plugins let you edit or reject each event before the events are stored. You can read more about the plugin server here https://posthog.com/docs/runbook/services/plugin-server

If you need even more security you can avoid sending the events at all. You can read more about how to do that in the PostHog documentation

Since that tutorial was written PostHog has added allowlists in the JS SDK to help further reduce automatic capture https://github.com/PostHog/posthog-js/pull/481

(Full disclosure - I work at PostHog)