Skip to content

Increase number of connections to the codes DB#354

Merged
BryceStevenWilley merged 1 commit intomainfrom
increase_db_conns
Feb 24, 2026
Merged

Increase number of connections to the codes DB#354
BryceStevenWilley merged 1 commit intomainfrom
increase_db_conns

Conversation

@BryceStevenWilley
Copy link
Collaborator

Currently tests in LITEFile are failing with the following:

Categories response: status=500 body=b'...Error 500 java.lang.RuntimeException: java.sql.SQLException: Could not retrieve connection info from pool</title>\n</head>\n<body><h2>HTTP ERROR 500 java.lang.RuntimeException: java.sql.SQLException: Could not retrieve connection info from pool</h2>\n<table>\n<tr><th>URI:</th><td>/jurisdictions/illinois/codes/courts/adams/categories</td></tr>\n<tr><th>STATUS:</th><td>500</td></tr>\n<tr><th>MESSAGE:</th><td>java.lang.RuntimeException: java.sql.SQLException: Could not retrieve connection info from pool</td></tr>\n<tr><th>SERVLET:</th><td>-</td></tr>\n<tr><th>CAUSED BY:</th><td>java.lang.RuntimeException: java.sql.SQLException: Could not retrieve connection info from pool</td></tr>\n<tr><th>CAUSED BY:</th><td>java.sql.SQLException: Could not retrieve connection info from pool</td></tr>\n<tr><th>CAUSED BY:</th><td>java.util.NoSuchElementException: Timeout waiting for idle object ...

FAILED efile/tests/tests.py::TestEdgeCasesAndErrorHandling::test_multiple_simultaneous_api_calls - assert False

This clearly points to the fact that we should bump the number of connections that we're allowed to make to the database at the same time. Supabase docs give a minimum of 60 direct connections that can be made, so increasing this by a bit. Also bumping the timeout to 400ms, since from a quick look at our prod stats, most queries finish by that time (only outlier being the optional services query).

@BryceStevenWilley BryceStevenWilley self-assigned this Feb 24, 2026
@BryceStevenWilley BryceStevenWilley added the ops Operations, i.e. production running label Feb 24, 2026
@BryceStevenWilley BryceStevenWilley merged commit deaaa37 into main Feb 24, 2026
4 checks passed
@BryceStevenWilley BryceStevenWilley deleted the increase_db_conns branch February 24, 2026 22:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ops Operations, i.e. production running

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant