Moved logging to engine