feat(table): per-plan table dispatch concurrency with env overrides#5720
Conversation
Greptile SummaryThis PR adds billing-plan-aware concurrency for table dispatches. The main changes are:
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Reviews (5): Last reviewed commit: "improvement(table): collapse dispatch co..." | Re-trigger Greptile |
|
@cursor review |
|
@cursor review |
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
999c2be to
e5d2bd5
Compare
PR SummaryMedium Risk Overview Concurrency is resolved once when a manual run starts ( The Reviewed by Cursor Bugbot for commit 57c9fe7. Bugbot is set up for automated code reviews on this repo. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit e5d2bd5. Configure here.

Summary
TABLE_DISPATCH_CONCURRENCY_{FREE,PAID}; billing-disabled deployments use the highest configured tierrunWorkflowColumn(same billing attribution the cells are billed under) and threaded through the dispatcher invocation — thetable-run-dispatchertask payload / in-process loop arg. No schema change; payloads without the field fall back to the legacy cap of 20workflow-group-celltrigger.dev queue cap now derives from the highest configured tier (getMaxTableDispatchConcurrency()) instead of a second hardcoded 20, so the two can't driftbatchEnqueueAndWaitnow enforces the sharedconcurrencyKeycap (same semaphore asrunInline), so overlapping dispatches on one table share the per-table limitType of Change
Testing
Unit tests for the plan resolver (buckets, env overrides, billing-disabled) and the shared batch semaphore. Full
lib/table+async-jobssuites, type-check,lint:check, andcheck:api-validation:strictall pass.Checklist
🤖 Generated with Claude Code
https://claude.ai/code/session_016jTmy5BZiCzSrcBcY6Pf6N