Repository navigation
fix(pool): reject negative minimum idle configuration - #6738
Open
cangen185-sudo wants to merge 1 commit into
Open
cangen185-sudo wants to merge 1 commit into
cangen185-sudo wants to merge 1 commit into
Conversation
cangen185-sudo
marked this pull request as ready for review
October 15, 2026 01:27
cangen185-sudo
marked this pull request as draft
October 15, 2026 01:28
cangen185-sudo
marked this pull request as ready for review
October 15, 2026 01:43
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.
Description
Reject negative incoming
minIdlevalues in both the setter and property-configuration paths.DruidAbstractDataSource.setMinIdle(int value)currently checks the oldminIdlefield rather thanvalue, sosetMinIdle(-1)is accepted from a normal nonnegative state.DruidDataSource.configFromProperties()also assignsdruid.minIdledirectly, bypassing that setter.Check
value < 0, and route the property assignment throughsetMinIdle(). Keep the existing pairedmaxActive/minIdlevalidation and the order that applies the new maximum before the new minimum. Valid zero/positive values retain their behavior.Reproduction and validation
Four added regressions cover negative values through the setter and properties, each before and after initialization. They verify that rejected input leaves the previous minimum unchanged and subsequent valid values remain usable. The initialized cases use the repository's existing mock JDBC driver.
82f4149ca41827b1cd64241e7b6e0684dba02a24, after a clean compilationCurrent verification command:
git diff --check: passed.Scoped Issue/PR searches for
minIdle,setMinIdleand negative minimums found no equivalent open repair. Historical #5558/#5562 concern error-message wording, not this incoming-value and property-path defect.The contributor has signed the CLA; the live
license/clacheck passed. GitHub Actions still requires maintainer approval.Codex assisted with audit, reproduction, implementation and validation. A bounded read-only review checked the paired property-reload semantics. Ready for maintainer review.