Skip to content

roachtest: structured errors, retries#95393

Closed
smg260 wants to merge 5 commits intocockroachdb:release-22.1from
smg260:backport22.1-81103-81845-84085-87304-93328
Closed

roachtest: structured errors, retries#95393
smg260 wants to merge 5 commits intocockroachdb:release-22.1from
smg260:backport22.1-81103-81845-84085-87304-93328

Conversation

@smg260
Copy link
Copy Markdown
Contributor

@smg260 smg260 commented Jan 17, 2023

In 2019, TeamCity released a new "experimental UI" that changed not
only the look and feel of the app, but also the URLs where pages are
located. Notably, information about a build used to be under the
/viewLog.html page in the old UI, but was moved to
/buildConfiguration/{buildTypeID}/{buildID} in the new UI.

If the user enabled the new UI locally, TeamCity will automatically
redirect requests from the old URLs to the new ones; however, the URL
fragments are not preserved. This is quite bad for roachtest, since
the links generated in failed test reports relies on the fragments in
order to expand the relevant folders in a potentially long list of
artifacts.

This commit updates TeamCity links generated by roachtest when
reporting failed tests to always use the new UI. It has the drawback
of forcing the new UI on everyone, but the benefit of always expanding
the correct folder.

A new environment variable, TC_BUILDTYPE_ID, was added to TeamCity
builds to support this use case; it contains the ID of the
corresponding build type (also known as "build configuration").

Resolves: #80852.

Release note: None.Backport:

Please see individual PRs for details.

/cc @cockroachdb/release

Renato Costa and others added 5 commits January 17, 2023 15:34
In 2019, TeamCity released a new "experimental UI" that changed not
only the look and feel of the app, but also the URLs where pages are
located. Notably, information about a build used to be under the
/viewLog.html page in the old UI, but was moved to
/buildConfiguration/{buildTypeID}/{buildID} in the new UI.

If the user enabled the new UI locally, TeamCity will automatically
redirect requests from the old URLs to the new ones; however, the URL
fragments are not preserved. This is quite bad for roachtest, since
the links generated in failed test reports relies on the fragments in
order to expand the relevant folders in a potentially long list of
artifacts.

This commit updates TeamCity links generated by roachtest when
reporting failed tests to always use the new UI. It has the drawback
of forcing the new UI on everyone, but the benefit of always expanding
the correct folder.

A new environment variable, `TC_BUILDTYPE_ID`, was added to TeamCity
builds to support this use case; it contains the ID of the
corresponding build type (also known as "build configuration").

Resolves: cockroachdb#80852.

Release note: None.
This commit changes the 'Parameters' section of a test
failure. Previously, it would only include the contents of the `TAGS`
and `GOFLAGS` environment variables. It now adds cluster configuration
values obtained from the `ClusterSpec`. These parameters are prefixed
with `ROACHTEST` (e.g., `ROACHTEST_cloud`).

For now, just the cloud name, number of CPUs and SSDs are included. In
the future, we can expand this work to support other relevant cluster
configuration values as needed to debug test failures.

Resolves: cockroachdb#80799.

Release note: None.
When artifacts are zipped in preparation for being published to
TeamCity, other zip files are skipped. The idea is that we won't try
to recursively zip artifacts.zip itself, or debug.zip, which is
published separately. However, some tests (notably, `tpchvec`)
download their own zip files in the `logs` directory so that they'll
be available for analysis when a test fails.

While there was an intention to skip only top-level zip files (as
indicated by existing comments), the code itself would skip any zip
files found in the `logs` directory. This commit updates the zipping
logic to skip only toplevel zip files, allowing tests to write their
own zip files to the `logs` directory and have them available for
inspection later.

Release note: None.
…orted.

Some runtime values are probabilistically set or otherwise have
defaults which are not evident at the time we report issues.

This change returns the vm options associated with a created cluster,
from which we can extract the final computed values for such fields
including the type of filesystem and whether encryption is enabled.

Release justification: test-only change
Release note: none
…test.

No previous coverage exists for posting issues to github. This change
moves the relevant code into a separate source file with associated test.
External functions dealing with actual issue posting to github, and loading
the TEAMS.yaml are now injected to facilitate easier testing.

Release justification: test-only change
Release note: none
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

@smg260 smg260 closed this Jan 17, 2023
@smg260 smg260 deleted the backport22.1-81103-81845-84085-87304-93328 branch January 17, 2023 21:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants