Repository navigation
Skip ignored workflow handler success callbacks - #283
Merged
Merged
Conversation
commit: |
Member
Author
This stack of pull requests is managed by Graphite. Learn more about stacking. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Workflow handler completion already returns immediately on success. Update the workpool development dependency to 0.4.12 and set
onCompleteExcludeKinds: ["success"]when scheduling async start, restart, and handler resume. Keep the peer dependency at^0.4.4: older clients ignore the option and preserve existing behavior, while 0.4.12 skips these unnecessary callbacks. Failure, cancellation, and ordinary step result handling are preserved.Compatibility verification used the published workpool 0.4.4 JavaScript client and its component in
convex-test. All six single/batch enqueue checks passed: the client omits the new option from serialized arguments, the component accepts the enqueue, and success/failure/cancellation callbacks still run. Only the development dependency and its lockfile resolution are upgraded.Use workpool's test registration helper to include its nested batch worker, and accommodate the newly
unknownsuccess result type in the existing size check.Validation: build and both TypeScript checks pass; 129 tests pass, including six new cases exercising callback exclusion and failure propagation for all three scheduling paths. Lint passes with three existing warnings. The change was also exercised in the isolated benchmark deployment in #284.
Stacked experiment #284 compares callback inclusion vs. exclusion on released 0.4.12, then evaluates transactional completion. Exclusion removes 600 callbacks per 100 five-step workflows (~18% fewer scheduled executions). Across three measured trials per configuration, median committed throughput changed by −20.7% at parallelism 25 and +9.6% at 100 (+6.6% including admission). Timing ranges are wide; the measured benefit is consistent callback elimination, not a universal throughput gain. See the full results.