def wait_on_app(port):
 retries = math.ceil((START_APP_TIMEOUT / BACKOFF_TIME))
 private_ip = appscale_info.get_private_ip()
 url = (((('http://' + private_ip) + ':') + str(port)) + FETCH_PATH)
 while (retries > 0):
  try:
   opener = urllib2.build_opener(NoRedirection)
   response = opener.open(url)
   if (response.code != HTTP_OK):
    logging.warning('{} returned {}. Headers: {}'.format(url, response.code, response.headers.headers))
   return True
  except IOError:
   retries -= 1
  time.sleep(BACKOFF_TIME)
 logging.error('Application did not come up on {} after {} seconds'.format(url, START_APP_TIMEOUT))
 return False

def wait_on_app ( port ) : retries = math . ceil ( ( START_APP_TIMEOUT / BACKOFF_TIME ) ) private_ip = appscale_info . get_private_ip ( ) url = ( ( ( ( 'http://' + private_ip ) + ':' ) + str ( port ) ) + FETCH_PATH ) while ( retries > 0 ) : try : opener = urllib2 . build_opener ( NoRedirection ) response = opener . open ( url ) if ( response . code != HTTP_OK ) : logging . warning ( '{} returned {}. Headers: {}' . format ( url , response . code , response . headers . headers ) ) return True except IOError : retries -= 1 time . sleep ( BACKOFF_TIME ) logging . error ( 'Application did not come up on {} after {} seconds' . format ( url , START_APP_TIMEOUT ) ) return False
waits for the application hosted on this machine .