refactoring.
messageNumber has to be inside the Message class
basic server is working