Encapsulated DBClient() and added custom events. Also added backend Socket.IO