refactoring
improve logging responsiveness