'Retrieves a profile by name.'

def GetProfileByName(self, profile_name, version=constants.PROFILE_REPOSITORY_VERSION, ignore_cache=False):

    if (not ignore_cache):
        profile = self._GetProfileFromCache(profile_name, version=version)
        if profile:
            return profile
    profile = super(CachingProfileServer, self).GetProfileByName(profile_name, version=version)
    if profile:
        self._StoreProfile(profile, version=version)
    return profile
