add semaphore
optimization of log mechanism
fixed #19