Icon

You are viewing the documentation of TeamCity 10.x and 2017.x, which is not the most recently released version of TeamCity.
View this page in the latest documentation or refer to the listing to choose the documentation corresponding to your TeamCity version.

 

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

In addition to statistic charts generated automatically by TeamCity on the Statistics tab, it is possible to configure your own statistical charts based on the set of statistic values provided by TeamCity or values reported from a build script. In the latter case you will need to configure your build script to report custom statistical data to TeamCity.

You can view statistic values reported by the build on the Build parameters page.

Info

The information in this section refers to TeamСity 10+. For other versions, refer to the listing to choose the corresponding documentation.

...

Name

Description

type
  • valueType describes a series of data shown on the chart. Each series is drawn with a separate color and you may choose one or another series using a filter.
  • valueTypes allows displaying several series on the chart by a pattern (described below)

key

The name of the valueType (series). It can be predefined by TeamCity, like BuildDuration or ArtifactsSize (see below Default Statistics Values Provided by TeamCity for the complete list of predefined statistic values), or you can provide your own data by reporting it from the build script.

title

The series name shown in the series selector. Defaults to <key>. For several series, pattern group markers can be used: {1} stands for the first captured group in the pattern, {0} stands for the whole pattern.

sourceBuildTypeId

This field allows you to explicitly specify a build configuration to use the data from for the given series. This field is mandatory for the first valueType used in a chart if the chart is added at the project level. In other cases it is optional. However, note that TeamCity chooses the build configuration to take the data from according to the following rules:

  1. if the sourceBuildTypeId is set within the valueType, the data is taken from this build configuration even if it belongs to a different project.
  2. if the sourceBuildTypeId is not set within current the valueType, but it is set in the valueType above the current one within the chart, the data from the build configuration referenced above will be taken. See example for the plugin-settings.xml file above.
  3. if the sourceBuildTypeId is not set within current the valueType and is not set above, the chart will show data for the current build configuration, i.e. this chart will work only for build configurations.

color

The color of a series to be used in the chart. Standard web color formats can be used - "#RRGGBB", color names, etc. For more information see HTML Colors reference and HTML Color Names reference. If not specified, an automatic color will be assigned based on the series title.

Anchor
patternedValues
patternedValues
pattern

Pattern for names of the Value Types (or series) to be shown on the chart. The asterisk (*) sign is allowed to filter Value Types (or series) either predefined by TeamCity, like BuildDuration or ArtifactsSize (see below Default Statistics Values Provided by TeamCity for the complete list of predefined statistic values), or your own data can be provided by reporting it from the build script.

...

If the predefined build metrics do not cover your needs, you can report custom metrics to TeamCity from your build script and use them to create a custom chart. There are two ways to report custom metrics to TeamCity:

...