@bp.route('/hgmo/<path:repo>/<rev>')
@api.apimethod(None, unicode, unicode, unicode, unicode, unicode, status_code=302)
def get_hgmo_archive(repo, rev, subdir=None, suffix='tar.gz', preferred_region=None):
    '\n    An archiver for hg.mozilla.org related requests. Uses relengapi.blueprints.archiver.get_archive\n\n    :param repo: the repo location off of hg.mozilla.org/\n    :param rev: the rev associated with the repo\n    :param subdir: optional subdir path to only archive a portion of the repo\n    :param suffix: the archive extension type. defaulted to tar.gz\n    :param preferred_region: the preferred s3 region to use\n    '
    rev = rev[0:12]
    src_url = current_app.config['ARCHIVER_HGMO_URL_TEMPLATE'].format(repo=repo, rev=rev, suffix=suffix, subdir=(subdir or ''))
    key = '{repo}-{rev}.{suffix}'.format(repo=repo, rev=rev, suffix=suffix)
    if subdir:
        key += '/{}'.format(subdir)
    return get_archive(src_url, key, preferred_region)
An archiver for hg.mozilla.org related requests. Uses relengapi.blueprints.archiver.get_archive

:param repo: the repo location off of hg.mozilla.org/
:param rev: the rev associated with the repo
:param subdir: optional subdir path to only archive a portion of the repo
:param suffix: the archive extension type. defaulted to tar.gz
:param preferred_region: the preferred s3 region to use
@bp.route('/hgmo/<path:repo>/<rev>')
@api.apimethod(None, unicode, unicode, unicode, unicode, unicode, status_code=302)
def get_hgmo_archive(repo, rev, subdir=None, suffix='tar.gz', preferred_region=None):
    '\n    An archiver for hg.mozilla.org related requests. Uses relengapi.blueprints.archiver.get_archive\n\n    :param repo: the repo location off of hg.mozilla.org/\n    :param rev: the rev associated with the repo\n    :param subdir: optional subdir path to only archive a portion of the repo\n    :param suffix: the archive extension type. defaulted to tar.gz\n    :param preferred_region: the preferred s3 region to use\n    '
    rev = rev[0:12]
    src_url = current_app.config['ARCHIVER_HGMO_URL_TEMPLATE'].format(repo=repo, rev=rev, suffix=suffix, subdir=(subdir or ))
    key = '{repo}-{rev}.{suffix}'.format(repo=repo, rev=rev, suffix=suffix)
    if subdir:
        key += '/{}'.format(subdir)
    return get_archive(src_url, key, preferred_region)