Hash both kafka and kafka-connect subtrees in BUILD_TREE_HASH#2411
Conversation
Hello delthas,My role is to assist you with the merge of this Available options
Available commands
Status report is not available. |
Request integration branchesWaiting for integration branch creation to be requested by the user. To request integration branches, please comment on this pull request with the following command: Alternatively, the |
|
/after_pull_request=2417 |
Waiting for other pull request(s)The current pull request is locked by the after_pull_request option. In order for me to merge this pull request, run the following actions first: ➡️ Merge the
Alternatively, delete all the after_pull_request comments from this pull request. The following options are set: after_pull_request |
71744a5 to
1725279
Compare
|
/approve |
solution/kafka_build_vars.sh previously hashed only solution/kafka. The same suffix is used for both the kafka and kafka-connect image tags (.github/workflows/end2end.yaml, solution/zenkoversion.yaml), so changes to solution/kafka-connect produced rebuilt images that were pushed under the existing tag — last-write-wins, no rebuild signal downstream. Combine the tree hashes of both subtrees via sha1sum so any change to either subtree invalidates the shared tag suffix. Same 40-char hex format, drop-in for all consumers. Considered a per-image hash variable so the kafka image would only re-tag when solution/kafka changes; rejected because the existing infrastructure assumes a single shared BUILD_TREE_HASH suffix across both images (solution/zenkoversion.yaml:99,102). After this lands, the first build produces a new tag for both images because the hashing algorithm itself changed. Old tags stay in the registry as historical artefacts. Issue: ZENKO-5275
1725279 to
8bca2da
Compare
027554f to
2d7a841
Compare
Waiting for other pull request(s)The current pull request is locked by the after_pull_request option. In order for me to merge this pull request, run the following actions first: ➡️ Merge the
Alternatively, delete all the after_pull_request comments from this pull request. The following options are set: after_pull_request, approve |
|
I have successfully merged the changeset of this pull request
The following branches have NOT changed:
Please check the status of the associated issue ZENKO-5275. Goodbye delthas. The following options are set: after_pull_request, approve |
Summary
solution/kafka_build_vars.sh:24now hashes bothsolution/kafkaandsolution/kafka-connectinto the sharedBUILD_TREE_HASHsuffix used by both image tags. Same 40-char hex format, drop-in for all consumers.Context
BUILD_TREE_HASHwas previouslygit rev-parse HEAD:solution/kafka— a tree hash covering only the kafka subtree. The same value is used as the suffix in both image tags:${KAFKA_IMAGE}:${KAFKA_TAG}-${BUILD_TREE_HASH}(kafka image)${KAFKA_CONNECT_IMAGE}:${KAFKA_CONNECT_TAG}-${BUILD_TREE_HASH}(kafka-connect image)Touched in
.github/workflows/end2end.yaml:346,361,solution/zenkoversion.yaml:99,102,.github/scripts/end2end/configure-e2e*.sh,solution/build.sh:88.Because the hash didn't include
solution/kafka-connect, any change to that subtree (Dockerfile edits, new plugins, build-arg additions) silently overwrote the existing kafka-connect image at the same tag in the registry. Surfaced during ZENKO-5274 (the SMT plugin being baked into a kafka-connect image whose tag was unchanged fromdevelopment/2.14).Approach
Combine the tree hashes of both subtrees via
sha1sum. Considered a per-image hash variable (so the kafka image would only re-tag whensolution/kafkachanges); rejected because the existing infrastructure assumes a single sharedBUILD_TREE_HASHsuffix across both images.Issue: ZENKO-5275