Conversation
Co-authored-by: Cursor <cursoragent@cursor.com>
When the global concurrent task limit is fully used, a Processor with a large backlog could stay at one task while Processors with nearly empty queues held the permits. One concurrent task now moves at a time from such a donor to the receiver: the donor gives up the task before the receiver may test it, and the receiver keeps it only if its throughput increases. Generated with [Snowflake CoCo](https://docs.snowflake.com/en/user-guide/cortex-code/cortex-code) Co-authored-by: Snowflake CoCo <noreply@snowflake.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
- Restored the no-op StandardNiFiServiceFacade.verifyComponentTypes so that flows with missing Processor types can be imported and pasted as ghost Processors - Removed AUTO scheduling checks from the flow synchronizer and flow snippet so that loading a flow on startup or cluster join never fails because of an unsupported scheduling strategy; validation marks such Processors invalid - Added the AUTO scheduling check to StandardProcessorDAO.verifyCreate, alongside the existing check in verifyUpdate - Removed AutoSchedulingIT.testContinuousFlowAdaptsToBlockingWork, which depended on the host having spare CPU Co-authored-by: Cursor <cursoragent@cursor.com>
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.
Summary
NIFI-16365
Implements the Automatic (Experimental) Processor scheduling strategy described in NIP-26.
Automatic scheduling starts with one concurrent task and adjusts the count one task at a time. It compares completed work before keeping a change and also considers waiting work, task use, back pressure, Processor yields and failures, CPU load, garbage collection pauses, and the instance-wide concurrent task limit.
For queue-consuming Processors that do not support session batching, a worker can retain its global permit for a bounded 10 millisecond burst of independent invocations. Each invocation retains normal Process Session and commit behavior. The next invocation performs the authoritative input and backpressure readiness check, avoiding duplicate connection scans, and the burst ends on no activity, elapsed time, scheduling changes, interruption, or retirement. Source and trigger-when-empty Processors are excluded.
The change also adds queue wake-up notifications, invocation and commit measurements, automatic scheduling details in diagnostics, user interface support, versioned flow handling, and system tests for supported and fallback Java versions.
Tracking
Issue Tracking
Pull Request Tracking
Pull Request Formatting
mainbranchVerification
VirtualThreadSchedulingAgentTestsuite passed: 39 testslinux/amd64and validated under sustained CDC flowBuild
./mvnw clean install -P contrib-checkLicensing
Documentation