Statistics customization

Skip to end of metadata
Go to start of metadata
You are viewing documentation of TeamCity 3.x, which is not the most recent released version of TeamCity. Please refer to the listing to choose another version.
Documentation Index

Statistics customization

TeamCity provides number of ways to customize statistics. You can add your own custom metrics to integrate your tools/processes, insert any stats graph/report into any extension place, etc.

Quick start

  • Easy way to just insert jsp fragment into WebPlace — use a helper bean
  • How to insert statistics chart into jsp page
  • Easy way to add a custom build metric: Extend BuildValueTypeBase to just define your build metric calculation method, appearance and key - now you can reference this metric by its key in statistics chart/report tags

More details

BuildType Statistics tab extension point

customizing appearance

  • width, height - graph image size
  • hideFilters - suppress filter controls

Details on how to add custom metrics

  • Implement jetbrains.buildServer.serverSide.statistics.ValueType
  • Register it via jetbrains.buildServer.serverSide.statistics.StatsManager

Details on custom Build metrics

  • Implement jetbrains.buildServer.serverSide.statistics.build.BuildFinishAware in your ValueType to be notified of build finished event
  • calculate your metric
  • Employ jetbrains.buildServer.serverSide.statistics.build.BuildDataStorage to publish your value
  • Employ jetbrains.buildServer.serverSide.statistics.build.BuildDataStorage to retrieve your dataset

Labels:

Enter labels to add to this page:
Wait Image 
Looking for a label? Just start typing.