Change log handling.
Merge pull request #368 from RomanZhilich/update_logger

Change log handling.