Repository navigation
Make the serverless final slice and base branch per service - #4830
Merged
Merged
Conversation
`release serverless` hard-coded `production-noncanary-ds-5` and `main`, so a service with other names could not be added. Each service now carries its own final slice and base branch, and the slice is matched by exact name instead of a slice-specific regex. Kibana and Elasticsearch keep their current values, so their output does not change. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Every walk test passed ds-5, so they would still pass if the commit filter or the YAML lookup ignored the requested slice. The new test uses ds-1 with distinct ds-1 and ds-5 versions and checks the version found and the commits read. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Contributor
Docs preview (local build)Handbook preview: https://docs-v3-preview.elastic.dev/elastic/docs-builder/pull/4830/ |
Mpdreamz
enabled auto-merge (squash)
November 12, 2026 13:28
Mpdreamz
added a commit
that referenced
this pull request
Nov 12, 2026
Empty commit. #4830 was squash-merged, so this branch is rebased onto main and needs a fresh run of the checks and the review bot. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
release serverlessnow reads the final production slice and the base branch from each service instead of two constants, so a service with other names can be added. Kibana and Elasticsearch keep their values and their output does not change.Affects: Release notes, CLI
Prompt summary: Onboard Elastic Cloud Hosted as a serverless release notes target, the way Kibana and Elasticsearch already are. ECH names its final slice and its main branch differently, so the first step is to stop hard-coding them. This pull request is that step, with no change in behaviour.
Why
ServerlessPromotionhard-codesproduction-noncanary-ds-5andmain, and two slice-specific regexes match only that name. A service with a different final slice cannot be registered without editing shared code.What
Final slice and base branch live on the service
ServerlessServicegainsFinalSliceandBaseBranch. Kibana and Elasticsearch registerproduction-noncanary-ds-5andmain. TheFinalSliceandBaseBranchconstants are gone, andServerlessReleaseCommandreads both from the service it resolved.Exact slice matching
A promotion commit message lists its slices, for example
production-noncanary-ds-4,production-noncanary-ds-5. One generated regex now reads that list, and the code compares each slice by exact name. A second generated regex readsversions.yamllines and the code picks the one for the service's slice. Both stay AOT-safe.Search options in one record
FindPreviousVersionAsynctakes aPreviousVersionSearchrecord (final slice, current version, page limit) so the method stays within four parameters.Verify
The existing cases keep their expectations; only their calls pass the slice. Making
IsFinalSlicePromotionacceptds-1failsIsFinalSlicePromotion, as it should.Stack: 1 of 2. Followed by #4831, which adds Elastic Cloud Hosted.
🤖 Generated with Claude Code