tools/bdconfig/lib/google_hadoop/bdconfig_lib/config_commands.py
def _ExtractDefaultBucketFromSystemBucket(self):
    """Tries falling back to system_bucket due to absence of default_bucket."""
    logging.warn('--default_bucket not specified. '
                 'Checking for system bucket in core-site.xml.')
    core_site_file_name = os.path.join(
        self._flags.hadoop_conf_dir, 'core-site.xml')
    conf = xml_configuration.Configuration.FromFile(core_site_file_name)
    system_bucket = conf.GetPropertyValue('fs.gs.system.bucket')
    if not system_bucket:
      raise KeyError('fs.gs.system.bucket not found in core-site.xml')
    else:
      logging.warn('fs.gs.system.bucket found as "{0}". '
                   'Using in fs.default.name'.format(system_bucket))
      return system_bucket
Tries falling back to system_bucket due to absence of default_bucket.
Tries falling back to system_bucket due to absence of default_bucket.
Tries falling back to system_bucket due to absence of default_bucket .
def _ExtractDefaultBucketFromSystemBucket(self):
    logging.warn('--default_bucket not specified. '
                 'Checking for system bucket in core-site.xml.')
    core_site_file_name = os.path.join(
        self._flags.hadoop_conf_dir, 'core-site.xml')
    conf = xml_configuration.Configuration.FromFile(core_site_file_name)
    system_bucket = conf.GetPropertyValue('fs.gs.system.bucket')
    if not system_bucket:
      raise KeyError('fs.gs.system.bucket not found in core-site.xml')
    else:
      logging.warn('fs.gs.system.bucket found as "{0}". '
                   'Using in fs.default.name'.format(system_bucket))
      return system_bucket
def _ExtractDefaultBucketFromSystemBucket ( self ) : logging . warn ( '--default_bucket not specified. ' 'Checking for system bucket in core-site.xml.' ) core_site_file_name = os . path . join ( self . _flags . hadoop_conf_dir , 'core-site.xml' ) conf = xml_configuration . Configuration . FromFile ( core_site_file_name ) system_bucket = conf . GetPropertyValue ( 'fs.gs.system.bucket' ) if not system_bucket : raise KeyError ( 'fs.gs.system.bucket not found in core-site.xml' ) else : logging . warn ( 'fs.gs.system.bucket found as "{0}". ' 'Using in fs.default.name' . format ( system_bucket ) ) return system_bucket
Tries falling back to system_bucket due to absence of default_bucket.
Tries falling back to system_bucket due to absence of default_bucket .
"""Tries falling back to system_bucket due to absence of default_bucket."""
self