I want to monitor the web portal availability on frequently basis like for every 10-20 minutes I will check tha e URL that the application is working fine or not . I want to monitor the health of the application with URL and Login into application and generate the report.

So please inform how to write a java code to check the application avlability,