more robust logger configuration