Added more logging support to engine API