[Improvement] Increase the default database connection pool max wait time #3427
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.
… time (#3419)
Why are the changes needed?
The default database connection pool max wait time is 1000ms for now.
This is quite small and the wait timeout exception is easy to occur when the database system is a bit busy.
Resolve #3419 .
Brief change log
Change the default value of DB_CONNECT_MAX_WAIT_MILLIS to 30000 in AmoroManagementConf.java(amo-ams).
Change the default value of connection-pool-max-wait-millis to 30000 in amoro-configmap.yaml(charts) and config.yaml(dist).
The reason for choosing 30000 instead of 5000 is that the default connectionTimeout value of HikariCP is 30000 milliseconds (the default value of max-wait-millis of DBCP2 is -1), and the default values of mainstream database connection pools are almost 30000ms or larger.
Documentation
Does this pull request introduce a new feature?
No