I'm trying to see what IP's on a list are actually online. I'm currently using
public boolean IsOnline(String ip) {
try (Socket s = new Socket(ip, 80)) {
return true;
} catch (IOException ex) {
}
return false;
}
To check if the server is online. But it takes about 30 seconds for each IP to get checked. Is there a way to get faster results like another kind of method?