update logging, fix issue with empty body
add explicit logger setting
improve exception handling