def create_java_app_env(app_name):
 env_vars = {'APPSCALE_HOME': constants.APPSCALE_HOME}
 config_file = find_web_xml(app_name)
 custom_env_vars = extract_env_vars_from_xml(config_file)
 env_vars.update(custom_env_vars)
 gcs_config = {'scheme': 'https', 'port': 443}
 try:
  gcs_config.update(deployment_config.get_config('gcs'))
 except ConfigInaccessible:
  logging.warning('Unable to fetch GCS configuration.')
 if ('host' in gcs_config):
  env_vars['GCS_HOST'] = '{scheme}://{host}:{port}'.format(**gcs_config)
 return env_vars

def create_java_app_env ( app_name ) : env_vars = { 'APPSCALE_HOME' : constants . APPSCALE_HOME } config_file = find_web_xml ( app_name ) custom_env_vars = extract_env_vars_from_xml ( config_file ) env_vars . update ( custom_env_vars ) gcs_config = { 'scheme' : 'https' , 'port' : 443 } try : gcs_config . update ( deployment_config . get_config ( 'gcs' ) ) except ConfigInaccessible : logging . warning ( 'Unable to fetch GCS configuration.' ) if ( 'host' in gcs_config ) : env_vars [ 'GCS_HOST' ] = '{scheme}://{host}:{port}' . format ( ** gcs_config ) return env_vars
returns the environment variables java application servers uses .