What's New in TeamCity 2024.03
New Bundled Plugin: HashiCorp Vault
The HashiCorp Vault Support plugin is now an integral component of the standard TeamCity installation. This plugin allows you to store sensitive data in a remote source, and enables TeamCity parameters to seamlessly retrieve these values during build processes.
![Vault connection settings Vault connection settings](https://resources.jetbrains.com/help/img/teamcity/2024.07/dk-vaultConnection.png)
To set up the TeamCity integration with HashiCorp Vault, create a new Vault connection and use it to set up the Remote secret parameter in the updated Add New Parameter dialog.
Learn more: HashiCorp Vault Integration.
Untrusted Builds
With the Pull Requests feature added to your configurations you can assess new code before integrating it into the primary codebase. This feature comes with filtering options, enabling you to select whether to run builds from any contributors or solely those affiliated with your organization. The former choice poses a notable security risk, potentially exposing your TeamCity server to malicious code camouflaged within pull requests. Conversely, opting for the latter restricts collaboration opportunities with a broader audience.
Version 2024.03 introduces a new setup that eliminates this trade-off between collaboration and security. The new Untrusted Builds group under project settings allows TeamCity to differentiate changes authored by trusted users from changes coming from an external source. New builds are triggered regardless of the changes' author, but builds that incorporate unverified changes will remain in queue until a designated reviewer (or a group of reviewers) marks them as safe to run.
![Pending approval Pending approval](https://resources.jetbrains.com/help/img/teamcity/2024.07/dk-untrustedbuilds-pending.png)
Learn more: Untrusted Builds.
New dotCover Runner
The new dotCover runner can automatically retrieve code coverage snapshots from multiple preceding .NET steps, and use these individual snapshots to publish a single coverage report.
![DotCover Runner Settings DotCover Runner Settings](https://resources.jetbrains.com/help/img/teamcity/2024.07/dk-dotcover-settings.png)
Learn more: dotCover.
Automatic Retry of Failed .NET Tests
If the .NET runner executes the test
or vstest
command, the runner's settings now display the new Test retry count option. This field allows you to specify how many times during the same build TeamCity can re-run failed test. Failed tests are re-launched until they either achieve success or exhaust the maximum number of attempts.
![Flaky tests during a re-run Flaky tests during a re-run](https://resources.jetbrains.com/help/img/teamcity/2024.07/dk-test-rerun-flaky.png)
This technique allows you to identify flaky tests and distinguish them from genuinely problematic tests that consistently fail regardless of the number of launch attempts.
Learn more: .NET | Vstest Command.
Gradle Configuration Cache
Starting with this version, you can enable the configuration cache feature for Gradle builds running in TeamCity. This feature substantially enhances build performance by caching the configuration phase's result and reusing it in subsequent builds.
Learn more: Configuration Cache.
Optional Artifact Dependencies
by other configurations (or by previous builds of the same configuration). To create these dependencies, you need to specify Artifacts Rules that define what files should be downloaded and where they should be stored.
If TeamCity is unable to locate files matching these rules, a build fails with the "Unable to resolve artifact dependency" error. This behavior does not take into account more flexible setups where a downloaded artifact is not mandatory for a dependent build to run.
Starting with version 2024.03, you can run a dependent build even if its artifact rules yield no files. To do so, start an artifact rule with the ?:
prefix.
![Optional dependency warning Optional dependency warning](https://resources.jetbrains.com/help/img/teamcity/2024.07/dk-relativeBuild-failed.png)
Learn more: Artifact Dependencies
Enhanced Git LFS and Submodules Support
Large File Systems and submodules are integral parts of many complex software solutions that import standalone repositories and offload massive files (videos, bitmaps, databases, and so on) to external hostings. In version 2024.03, you can add parameter-based credentials to your TeamCity projects. When checking out source files, TeamCity will use these credentials to access and download required files. This feature allows you to set up TeamCity integration with Sonatype Nexus LFS repositories) and other popular solutions.
Learn more: LFS and Submodules Support.
New Parameter Dialog
In version 2024.03 we have redesigned the Add/Edit Parameter dialog that you utilize when configuring build parameters.
![Single select parameter settings Single select parameter settings](https://resources.jetbrains.com/help/img/teamcity/2024.07/dk-newparams-singleselect.png)
In addition to other notable enhancements, the updated dialog allows you to select a new parameter type — Remote secret. Choose this type for parameters whose values should be retrieved from a remote source (for example, HashiCorp Vault).
Learn more: Create and Set Up Custom Parameters.
Alternative Fetch URLs
In TeamCity 2024.03, build agents can now fetch sources from a pre-configured repository proxy that mirrors your original Git repository. This capability is especially valuable for large distributed systems, mitigating connectivity issues for agents distant from the primary repository.
Fetch URL mapping rules, defined in agent configuration files, offer granular control over the checkout process per agent. Additionally, wildcard and partial URL support in redirection rules enables the creation of universal, project-agnostic mapping patterns.
Learn more: Git VCS Root | General Settings.
Miscellaneous Changes
The Open Terminal button now opens the terminal in the checkout directory. If invoked from the agent's overview page, the terminal still opens in the
$HOME
directory.New Commit Status Publisher setting allows you to choose whether you want TeamCity to post Swarm review comments when a build finishes. If this option is disabled, the build feature will only update the review's Tests section.
The Parameters | Statistic values section of composite builds now includes an additional metric that displays how much time this build saved by reusing previous builds instead of running them anew.
Roadmap
See the TeamCity roadmap to learn about future updates.
Your Feedback Matters
We place a high value on your feedback and encourage you to share your thoughts and suggestions. See this link for more information: Feedback.