This reverts commit 41a2a32f66. Performs worse in some cases than what we had before.
41a2a32f66
Generic single-database configuration.