my implementation of logger - thread-safely, expandable and fast