This is part of the effort to enable multi-version support in hand-written libraries. More context and details in this doc.
This PR adds two workflows and their scripts:
update_generation_config which updates generation_config.yaml (added in this PR) to contain the latest googleapis_committish (source of truth of library generation) as well as other dependencies such as gapic_generator_version. This job runs nightly and creates a PR that modifies the config yaml.
hermetic_library_generation which reads generation_config.yaml and pushes a new commit to any PR whose latest commit affects generation_config.yaml (e.g. the nightly PR created by update_generation_config). It essentially translates changes in the config yaml to changes in the source code (of the generated part). This workflow will be a required check.
As an example of how they work in practice:
Once per night, update_generation_config creates a PR that updates generation_config.yaml with the latest dependencies and googleapis committish
hermetic_library_generation is triggered by this PR and generates the corresponding code changes. A new commit with the code changes is added to the PR. This step may occur for any PR affecting generation_config.yaml.
Follow ups
[x] Add CLOUD_JAVA_BOT_TOKEN to repository for the hermetic generation workflow to work. We confirmed it works in our fork (job link).
This is part of the effort to enable multi-version support in hand-written libraries. More context and details in this doc.
This PR adds two workflows and their scripts:
update_generation_config
which updatesgeneration_config.yaml
(added in this PR) to contain the latestgoogleapis_committish
(source of truth of library generation) as well as other dependencies such asgapic_generator_version
. This job runs nightly and creates a PR that modifies the config yaml.hermetic_library_generation
which readsgeneration_config.yaml
and pushes a new commit to any PR whose latest commit affectsgeneration_config.yaml
(e.g. the nightly PR created byupdate_generation_config
). It essentially translates changes in the config yaml to changes in the source code (of the generated part). This workflow will be a required check.As an example of how they work in practice:
update_generation_config
creates a PR that updatesgeneration_config.yaml
with the latest dependencies and googleapis committishhermetic_library_generation
is triggered by this PR and generates the corresponding code changes. A new commit with the code changes is added to the PR. This step may occur for any PR affectinggeneration_config.yaml
.Follow ups
CLOUD_JAVA_BOT_TOKEN
to repository for the hermetic generation workflow to work. We confirmed it works in our fork (job link).