I want a Node JS server to communicate with a UDP or TCP client.
My questions:
- What are the steps or suggestion when i want to create socket client with another language , but the server is using nodejs?
- I have created UDP client with java, but when i want to connect to the Node JS server, i couldn’t connect. I think in node js any something rule to connect to server, how your opinion?
TCP and UDP sockets are not language-dependant, if you have an UDP server in NodeJS, and an UDP Client in Java, this should work out of the box.
So you must be doing something wrong in your NodeJS or Java program. Here’s a simple Hello world program :
Server.js :
and UDPClient.java :