add logger and threads