feat: enable hermetic library generation#2234
Conversation
| @@ -0,0 +1,37 @@ | |||
| protoc_version: '25.3' | |||
There was a problem hiding this comment.
can you add a comment here and in the existing owl bot config that these are mirrors of each other?
There was a problem hiding this comment.
Actually protoc version is now baked into our docker image, @diegomarquezp can you please remove it to reflect the recent changes?
The protoc version used to come from the googleapis/WORKSPACE, which is shared by all languages. This is now configurable by Java.
| - name: Generate changed libraries | ||
| shell: bash | ||
| run: | | ||
| set -x |
There was a problem hiding this comment.
does this need a set -e?
| - name: Update params in generation config to latest | ||
| shell: bash | ||
| run: | | ||
| set -x |
There was a problem hiding this comment.
does this need a set -e?
| # 1. git | ||
| # 2. gh | ||
| # 3. jq | ||
|
|
There was a problem hiding this comment.
can you either add logging which commitish this processing? or at least set -x?
🤖 I have created a release *beep* *boop* --- ## [2.43.0](https://togithub.com/googleapis/java-bigtable/compare/v2.42.0...v2.43.0) (2024-08-22) ### Features * Add fields and the BackupType proto for Hot Backups ([#2300](https://togithub.com/googleapis/java-bigtable/issues/2300)) ([acaa3ff](https://togithub.com/googleapis/java-bigtable/commit/acaa3ff26ab0d317362e2be65ac5edcf803b13a1)) * Allow non default service account in DirectPath ([#2312](https://togithub.com/googleapis/java-bigtable/issues/2312)) ([09d0f23](https://togithub.com/googleapis/java-bigtable/commit/09d0f23032488dfa55c7a4c1c571a4f36bd94728)) * **bigtable:** Remove deprecated Bytes from BigEndianBytesEncoding ([#2309](https://togithub.com/googleapis/java-bigtable/issues/2309)) ([32f244f](https://togithub.com/googleapis/java-bigtable/commit/32f244f13d0c8571654d314310a4756fe275d609)) * Enable hermetic library generation ([#2234](https://togithub.com/googleapis/java-bigtable/issues/2234)) ([169aea5](https://togithub.com/googleapis/java-bigtable/commit/169aea5c43485a8d13ed53f57495609c142944df)) ### Bug Fixes * Add missing call to EqualsTester#testEquals ([#2307](https://togithub.com/googleapis/java-bigtable/issues/2307)) ([8b49f9c](https://togithub.com/googleapis/java-bigtable/commit/8b49f9ce84871f0f423f5837785604c3119ccd88)) ### Dependencies * Update shared dependencies ([#2314](https://togithub.com/googleapis/java-bigtable/issues/2314)) ([ab392ee](https://togithub.com/googleapis/java-bigtable/commit/ab392ee8d0c4535b5d3f31b3e111cbc41b399dd9)) --- This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please).
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_configwhich 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_generationwhich readsgeneration_config.yamland 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_configcreates a PR that updatesgeneration_config.yamlwith the latest dependencies and googleapis committishhermetic_library_generationis 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_TOKENto repository for the hermetic generation workflow to work