i'm working on a small project where i need to communicate with node.js server(it has rest services) from android client...i referred this link Combining java and nodejs for android app... is there any way where i can communicate instead of web sockets.
Check out this http://www.mkyong.com/webservices/jax-rs/restfull-java-client-with-java-net-url/, it includes a simple server example as well, but I think the client code should be useful to you.
There is also this SO question which should have more useful information for you.
If you creating WebApp it helpful Socket.io
I've used Gottox API on Android to connect to a Node.js+Socket.IO server without problems.
I also tried android-websockets before, but had some problems (see this question) that are probably already solved. Give it a try.