Added some database configuration handling