Programmed some ideas, in particular the pool thread for handling connections.