Skip to content

Releasing infrastructure#


The text below contains Avito specific details

We publish releases to Maven Central:

Publishing a new release#

If you release for the first time
  1. Check if diff against the last release contains any changes for users. If not, then probably there are no reasons to make a release.
  2. Check the current status of Nightly Avito integration build.
    If it is Failed you could release from previous Succeed commits or fix problems.
  3. Checkout a release branch with a name equals to projectVersion. For example, 2021.9.
    This branch must be persistent. It is used for automation.
  4. Manually run Integration build on the release branch.
  5. Manually run Github publish configuration on the release branch. It will upload artifacts to a staging repository in Sonatype. So you can upload it in advance at any previous step and drop in case of problems.
  6. Release staging repository
  7. Make a PR to an internal avito repository with the new version of infrastructure.
  8. Checkout a new branch and make a PR to github repository:
    • Change infraVersion property in the ./ to the new version
    • Bump up a projectVersion property in the ./ to the next version
  9. Publish a release in Github:
    make draft_release version=<current release version> prev_version=<last release version>
    You need to have the Github cli.
    See also more details about Managing releases in a repository.

Getting access to Sonatype#

  1. Create an account
  2. Create an issue referencing original one, asking for access
  3. Wait for confirmation
  4. Login to nexus to validate staging profile access

Some additional info:

Making a release in Sonatype#

We publish a release through a temporary staging repository. If something goes wrong you can drop the repository to cancel the publication process.

  1. Open Staging repositories oss-avito In a Content tab you can see uploaded artifacts.
  2. Close the repository:
    You don’t need to provide a description here. oss-close In an Activity tab you can track progress. oss-release
  3. Release the repository. It will publish the contents to Maven Central oss-release-confirm
  4. Wait till new packages appear on Maven Central. It takes usually about 15-30 min. You can see them earlier in a repository manager or in public search before all of them will be available for download.

Some additional info:

Known issues#

Can't find an artifact in an internal Artifactory#

How it looks:

  • Maven central has expected artifacts: pom, jar/aar, sources.jar
  • Gradle can't find it in Artifactory Proxy
> Could not resolve all artifacts for configuration ':classpath'.
   > Could not find
     Searched in the following locations:
       - file:/home/user/.m2/repository/
       - http://<artifactory>/

Probable reasons:

  • The file is not downloaded by Artifactory yet. Such files look in web UI like empty references: runner-shared-2020.16.jar-> - - - - (empty size)
  • When you use a partially uploaded release, Artifactory might cache the wrong state. It seems that Artifactory caches it for some time, but we don't know exactly and how to invalidate it.


  • Download this file manually in the browser or CLI.
    If the file downloaded successfully, refresh a local cache via --refresh-dependencies.
  • If it didn't help, bump up a minor release version and make a new release.

Local integration tests against Avito#

Using mavenLocal#

  1. Run make publish_to_maven_local in github repository.
  2. Run integration tests of your choice in avito with specified test version

Using compositeBuild#

Run from Avito project directory

./gradlew <task> -Pavito.useCompositeBuild=true -Pavito.compositeBuildPath=<avito-android-infra/subprojects dir on your local machine>

CI integration tests against Avito#

  1. Choose configuration from existed
  2. Run build.
    If you need to test unmerged code, select a custom build branch.
    You will see branches from both repositories:

  • By default, build uses develop from github against develop from avito
  • If you pick a branch from avito, it will run against develop on github
  • If you pick a branch from github, it will run against develop on avito
  • To build both projects of special branch, they should have the same name

CI integration configurations#