I need to send image to client whenever it's available in the server. The client is not a browser but some kind of device(linux box) behind NAT (3G network) that will get the image as a file, write it to disk then display it in a screen (no browser here).
I'm new to nodejs and websocket.
Can I use a nodejs as a websocket client in the device and a nodejs as a server? Can you provide an example of using nodejs to execute a websocket client?
In this case, can nodejs detect 3G network loss then resume or restart the websocket?
What happen if connection loss happen while nodejs server is pushing an image to the device nodejs (client)? is there any resume solution?
how about Binary Js to handle file transfer between the 2 nodejs?
Can I do that with some pub/sub mecanism using a MOM like ActiveMQ?