Performance Sampling filter on time

Hi, I’m just getting started with Performance monitoring in my Django project. I’m wanting to reduce the transaction volume by using a traces_sampler filter function: Sampling Transactions for Django | Sentry Documentation

Is it possible to always send a transaction if it’s run time is slow, say more then 1 second?

I see that there is start_timestamp in sampling_context. But the traces_sampler function appears to be called before my Django view function.

Is there a way to filter samples after my code has run?

Thanks!

Hi, sorry for the late reply. You cannot currently un-sample (we use simple head-based sampling), and doing so would skew all kinds of statistics in the product as well. We have something planned for this for this year but it’s not clear what it will look like yet. Stay tuned.