title: Check if Wildfly Server is running with my app?
body: <p>I would like to know how can I check if my Wildfly Server is running and the WebApp has been deployed?</p>
  
  <p>Currently I check only if the server is running.</p>
  
  <pre><code>public static boolean checkServerAvailable() {
      try {
  
          String url = Constants.URL_APP + ":" + Constants.APPSERVER_PORT;
  
          HttpURLConnection.setFollowRedirects(false);
          // note : you may also need
          // HttpURLConnection.setInstanceFollowRedirects(false)
          HttpURLConnection con = (HttpURLConnection) new URL(url)
                  .openConnection();
          con.setRequestMethod("HEAD");
  
          if (con.getResponseCode() == HttpURLConnection.HTTP_OK) {
              return true;
          }
  
          else
              return false;
  
      } catch (Exception e) {
          return false;
      }
  }
  </code></pre>
  
  <p>But I need to know if the Wildfly server also my web app deployed successull.</p>