Second commit
Implemented the buffer feature on the server
Implemented the database connection
Small modifications, fixes and improvings.