Inject GerritRemoteReader instance

When a manifest contains a project in a second host, the manifest parser
generates a correct .gitmodules but the GerritRemoteReader ignores the
host and tries to read the sha1 of the submodule from <this
host>/<project>. In some cases this produces an inconsistent
superproject: the .gitmodules points to a repo but the SHA1 in the
gitlink doesn't exist there.

Cross-host is a feature of the backend, the default implementation
should not count on it.

Make the GerritRemoteReader injectable, so providers can use a
cross-host implementation if supported in their platform.

Change-Id: I0475348373dd3c6c750ced864728c07c82b831b5
2 files changed
tree: b370109246937e9844aff47885d4f2eb78ec3dcb
  1. java/
  2. javatests/
  3. BUILD
  4. LICENSE
  5. README.md
README.md

The plugin will update a superproject to contain the submodules defined in the manifest XML file whenever the manifest repo is changed.

For more information see the documentation.