I'm developing a messaging app using MQTT, after moving off GCM due to multiple failures.
I have a server broker online, and a client connecting and subscribing to it, and receiving messages of subscribed topics.
Now I'm thinking about to what to subscribe to and what message to send. I have a server for the GCM implementation (user id, google key); I think I don't need that anymore? I thought about subscribing to the broker with the user ID and if user B wants to send a message to user A, then B publish a message to the A user's ID topic... but with that kind of implementation, anyone could "sniff" conversations subscribing to random IDs.
So, I have a working MQTT server and client, and I don't know how to correctly use them for a messaging app...
I could think about it, but I suspect this would be a well known problem with an already known solution...
thank you very much!