Mongo based chat client in C++