added some logging again and config