DEPRECATED!!!
    return the latest version of our base AMI
    we can't use tags for this, so we have only the name as resource
    note: this functionality is deprecated since this only works for "old"
    baseami.
549124
def get_base_ami(awsclient, owners):
    
    client_ec2 = awsclient.get_client('ec2')
    image_filter = [
        {
            'Name': 'state',
            'Values': [
                'available',
            ]
        },
    ]

    latest_ts = maya.MayaDT(0).datetime(naive=True)
    latest_version = StrictVersion('0.0.0')
    latest_id = None
    for i in client_ec2.describe_images(
            Owners=owners,
            Filters=image_filter
            )['Images']:
        m = re.search(r'(Ops_Base-Image)_(\d+.\d+.\d+)_(\d+)$', i['Name'])
        if m:
            version = StrictVersion(m.group(2))
            #timestamp = m.group(3)
            creation_date = parse_ts(i['CreationDate'])

            if creation_date > latest_ts and version >=latest_version:
                latest_id = i['ImageId']
                latest_ts = creation_date
                latest_version = version

    return latest_id
1228457
@Deprecated
  public String getVersion() {
    try {
      return new EtcdOldVersionRequest(this.client, retryHandler).send().get();
    } catch (IOException | EtcdException | EtcdAuthenticationException | TimeoutException e) {
      return null;
    }
  }
606500
def file_name(self, resource):
        """"""
        warnings.warn(
            "file_name is deprecated; use resource_name instead",
            DeprecationWarning, stacklevel=2)
        return self.resource_name(resource)
29538
private boolean isDeprecated( JavaMethod method )
    {
        if ( method == null )
            return false;

        for ( Annotation annotation : method.getAnnotations() )
        {
            if ( "java.lang.Deprecated".equals( annotation.getType().getFullyQualifiedName() ) )
            {
                return true;
            }
        }

        return method.getTagByName( "deprecated" ) != null;
    }
8723
def base_url(self):
        
        return get_current_url(
            self.environ, strip_querystring=True, trusted_hosts=self.trusted_hosts
        )
1342119
def set_asset_tag(asset_tag)
      @logger.warn '[Deprecated] `set_asset_tag` is deprecated. Please use `set_system_settings(AssetTag: <tag>)` instead.'
      new_action = { 'AssetTag' => asset_tag }
      response = rest_patch('/redfish/v1/Systems/1/', body: new_action)
      response_handler(response)
      true
    end
1151556
def get_resource_url(self):
        

        name = self.__class__.resource_name
        url = self.__class__.rest_base_url()

        if self.id is not None:
            return "%s/%s/%s" % (url, name, self.id)

        return "%s/%s" % (url, name)
1008328
def deprecated(context):
    """"""
    tar = context.get('tar', None)

    # at least 1 of tarExtract or tarArchive must exist in context
    tar_extract, tar_archive = context.keys_of_type_exist(
        ('tarExtract', list),
        ('tarArchive', list))

    found_at_least_one = (tar_extract.key_in_context
                          or tar_archive.key_in_context)

    if tar and not found_at_least_one:
        return
    elif found_at_least_one:
        tar = context['tar'] = {}

    if tar_extract.key_in_context and tar_extract.is_expected_type:
        tar['extract'] = context[tar_extract.key]

    if tar_archive.key_in_context and tar_archive.is_expected_type:
        tar['archive'] = context[tar_archive.key]

    if 'tarFormat' in context:
        tar['format'] = context['tarFormat']

    logger.warning("tarExtract and tarArchive are deprecated. They will "
                   "stop working upon the next major release. "
                   "Use the new context key env instead. It's a lot "
                   "better, promise! For the moment pypyr is creating the "
                   "new env key for you under the hood.")
707845
async def AdoptResources(self, model_tag, source_controller_version):
        '''
        
        '''
        # map input types to rpc msg
        _params = dict()
        msg = dict(type='MigrationTarget',
                   request='AdoptResources',
                   version=1,
                   params=_params)
        _params['model-tag'] = model_tag
        _params['source-controller-version'] = source_controller_version
        reply = await self.rpc(msg)
        return reply
560510
def get_resource_url(self):
        

        name = self.__class__.resource_name
        url = self.__class__.rest_base_url()

        return "%s/%s" % (url, name)
28410
def name(self):
        
        if self._meta and self._meta.get('name'):
            # get it from the meta file
            return self._meta.get('name')
        # infer it from the basename
        return self.basename.replace('_', ' ').title()
1028456
def get_root_resource(server_host, server_port=None,
                      username="admin", password="admin",
                      use_tls=False, version=API_CURRENT_VERSION):
  
  return ApiResource(server_host, server_port, username, password, use_tls,
      version)
678200
@Deprecated
    public List<Index> listIndices() {
        InputStream response = null;
        try {
            URI uri = new DatabaseURIHelper(db.getDBUri()).path("_index").build();
            response = client.couchDbClient.get(uri);
            return getResponseList(response, client.getGson(), DeserializationTypes.INDICES);
        } finally {
            close(response);
        }
    }
163525
def default_base_dir():
    
    base_dir = os.environ.get('OS_REFRESH_CONFIG_BASE_DIR')
    if base_dir is None:
        # NOTE(bnemec): Prefer the new location, but still allow the old one.
        if os.path.isdir(OLD_BASE_DIR) and not os.path.isdir(DEFAULT_BASE_DIR):
            logging.warning('Base directory %s is deprecated. The recommended '
                            'base directory is %s',
                            OLD_BASE_DIR, DEFAULT_BASE_DIR)
            base_dir = OLD_BASE_DIR
        else:
            base_dir = DEFAULT_BASE_DIR
    return base_dir
333961
@Deprecated
    User getCurrentUser(AccessToken accessToken) {
        BasicUser basicUser = getCurrentUserBasic(accessToken);
        return getResource(basicUser.getId(), accessToken);
    }
1279379
def deprecated(context):
    """"""
    if 'fileFormatIn' in context:
        context.assert_keys_have_values(__name__,
                                        'fileFormatIn',
                                        'fileFormatOut')

        context['fileFormat'] = {'in': context['fileFormatIn'],
                                 'out': context['fileFormatOut']}

        logger.warning("fileFormatIn and fileFormatOut "
                       "are deprecated. They will stop working upon the next "
                       "major release. Use the new context key fileFormat "
                       "instead. It's a lot better, promise! For the moment "
                       "pypyr is creating the new fileFormat key for you "
                       "under the hood.")
762034
def get_base_url(self):
        
        return "http://{hostname}:{port}/{api}".format(
                hostname=self.hostname,
                port=self.port,
                api=self.api_version)