Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

feat(workflows): raise batch trigger audience limits to 500k/1M (#87638)

Meikel Ratzedb6883bcfe6
diff --git a/nodejs/src/cdp/config.ts b/nodejs/src/cdp/config.ts
index 5d92c041b40c..177686e9c44f 100644
--- a/nodejs/src/cdp/config.ts
+++ b/nodejs/src/cdp/config.ts
@@ -319,7 +319,7 @@ export function getDefaultCdpConfig(): CdpConfig {
// Django's batch-job model always passes get_hogflow_batch_trigger_limit(team_id), so
// production batches use the per-team value from settings; this is only a safety net for
// direct callers (tests, admin tools). Match the fleet-wide default in settings.web.py.
- CDP_BATCH_WORKFLOW_MAX_AUDIENCE_SIZE: 50000,
+ CDP_BATCH_WORKFLOW_MAX_AUDIENCE_SIZE: 500000,
// Cyclotron Node
CYCLOTRON_NODE_MAX_CONNECTIONS: 10,
diff --git a/posthog/settings/web.py b/posthog/settings/web.py
index 98d638c59032..8d3e4647e97c 100644
--- a/posthog/settings/web.py
+++ b/posthog/settings/web.py
@@ -1184,11 +1184,11 @@ HOG_FUNCTIONS_DAILY_DIGEST_TEAM_IDS = get_list(get_from_env("HOG_FUNCTIONS_DAILY
# Maximum audience size for HogFlow batch triggers. Default that applies to all teams unless they
# opt in to the elevated value below. Only used to inform the frontend UI; no backend enforcement.
-HOGFLOW_BATCH_TRIGGER_LIMIT = int(get_from_env("HOGFLOW_BATCH_TRIGGER_LIMIT", 50000))
+HOGFLOW_BATCH_TRIGGER_LIMIT = int(get_from_env("HOGFLOW_BATCH_TRIGGER_LIMIT", 500000))
# Elevated maximum audience size, returned for teams listed in HOGFLOW_BATCH_TRIGGER_ELEVATED_TEAM_IDS.
-HOGFLOW_BATCH_TRIGGER_LIMIT_ELEVATED = int(get_from_env("HOGFLOW_BATCH_TRIGGER_LIMIT_ELEVATED", 100000))
+HOGFLOW_BATCH_TRIGGER_LIMIT_ELEVATED = int(get_from_env("HOGFLOW_BATCH_TRIGGER_LIMIT_ELEVATED", 1000000))
# Comma-separated list of team IDs that get the elevated batch trigger limit instead of the default.
-# Empty by default — everyone gets the 50k tier. Opt-in via env override for teams needing 100k.
+# Empty by default — everyone gets the 500k tier. Opt-in via env override for teams needing 1M.
HOGFLOW_BATCH_TRIGGER_ELEVATED_TEAM_IDS: set[int] = {
int(team_id) for team_id in get_list(get_from_env("HOGFLOW_BATCH_TRIGGER_ELEVATED_TEAM_IDS", ""))
}