Skip to content
Advertisement

Tag: ping

Preferred Java way to ping an HTTP URL for availability

I need a monitor class that regularly checks whether a given HTTP URL is available. I can take care of the “regularly” part using the Spring TaskExecutor abstraction, so that’s not the topic here. The question is: What is the preferred way to ping a URL in java? Here is my current code as a starting point: Is this any

Advertisement