I’m trying to make java program that checks ip addresses and it’s ports and return whether it is listening or not. Since it is web based programing that I’m doing, I want the program to be really light and efficient. Thanks in advance
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can try to use
SocketAPI from Java for this. If no one is listening at an IP:PORT, you get a “Connection refused” exception thrown. How you want to continue further check if the connection gets accepted is something you would/should know about.