Fixed logging issues with database and descriptors