Large Oracle/PostgreSQL schemas: freezes, slow metadata and dead connections - measurements and proposed fixes #42458
Unanswered
tessarotto21
asked this question in
DBeaver Development
Replies: 1 comment
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Hi everyone!
I've had a hard time using DBeaver with large databases: freezes while loading objects, the editor getting stuck when the connection drops, and autocomplete that never shows up. More than once that pushed me back to paid tools. Instead of giving up, I decided to try to contribute.
At work we use Oracle with a large dictionary: thousands of tables, packages, procedures, functions and indexes. With that schema size and a VPN in the middle, DBeaver was hard to use. Other tools handle schemas of this size, so I forked DBeaver and spent some time measuring where the time goes, working with Claude (Opus 5.5) as a coding assistant. Everything below comes from DBeaver's own code and from measurements. Nothing came from other products.
How I measured
ALL_*views.devel.What I found and changed
SCHEMA.on a cold connection.is typed while a parsing session is still reading metadata (race inSQLBackgroundParsingJob)Small bugs found along the way:
ALL_CONS_COLUMNSis hardcoded in two queries.PostgreExecutionContext.refreshDefaultsstores the current schema as the active user (queryStringsreads column 1 of each row). This affects$userresolution and the Redshift privilege filter.JDBCUtils.isConnectionAlivepasses milliseconds toConnection.isValid(seconds).For Oracle I also have an opt-in "keep table metadata between sessions" option, off by default:
LAST_DDL_TIME/STATUS.This is the largest change, and I'd like to hear your opinion on the approach before proposing it.
Related issues and discussions
I searched before posting. These seem to describe the same problems:
I didn't find existing reports for:
Proposal
I'd like to send these as small, independent PRs, each with its own issue, tests where possible, and before/after numbers:
Would you be interested in reviewing these? I'm happy to adjust the approach to whatever fits the project best, and I can share the benchmark scripts as well.
AI disclosure: this work was done with the help of Claude (Anthropic), and I reviewed and tested every change myself.
Thanks!
Isa
All reactions