added more logging, added test fix to streamhandler for zombie-thread bug