Add Jenkins template variables for slash normalization handling.

Review Request #13861 — Created May 15, 2024 and submitted — Latest diff uploaded

Information

rbintegrations
release-4.x

Reviewers

Our Jenkins implementation normalizes slashes in job names to
underscores, in order to avoid issues with certain versions of Jenkins.
It turns out that this really only applied to a specific range of
versions, and that both prior and latter versions need to retain the
slash. This behavior has been a blocker on supporting newer versions of
Jenkins.

Rather than try to determine what's best for the install, we now give
users more control over the process by way of new variable names.

The old {branch} and {repository} names (which normalized slashes in
some versions and didn't in others) are now deprecated and no longer
documented in the field's help text.

Instead, we now have {branch_name} and {repository_name}, which do
not normalize, and {noslash_branch_name} and
{noslash_repository_name}, which do normalize.

Existing configurations will continue to work as before, for the most
part. While the legacy variable names are still there, we no longer
normalize the entire job name, so if a job name had slashes explicitly
provided and expected them to be changed to underscores, they'll need to
update those to use underscores instead.

Because of the change to normalization rules across the provided job
name, this is considered a potentially breaking change, for those that
needed slashes normalized before, and will need to be documented as
such.

Unit tests pass.

Commits

Files