Code Churn Perspective
You can use the Code Churn perspective to view just the measures, attributes, and calculations in the data cube that pertain to the Team Foundation Build process. The Code Churn perspective helps you analyze how source files are changing over time and across builds.
Note
In order to use perspectives with the Team Foundation cube, you must use Microsoft SQL Server 2005 Enterprise Edition or SQL Server 2005 Enterprise (64) Edition on the data tier. SQL Server 2005 Standard Edition that ships as part of Team Foundation Server, does not support the use of perspectives. When you use SQL Server 2005 Standard Edition, the cube elements from all perspectives reside in the Team System data cube.
You can use the Code Churn perspective to answer questions such as:
How many files of a specific file name extension changed in a particular build?
How many lines of code are in the source base for a particular build?
Which changesets have been submitted, and the details of each change (for example, who performed the change, what files were modified, and the date the change was made).
Measures
The following table describes the measures that are included in the Code Churn perspective. The Code Churn perspective contains a single measure group named Code Churn. A new fact is added to this measure for each file change referenced by a check-in action in the version control system.
Measure |
Description |
---|---|
Code Churn Count |
The number of times that changes were made to files in the version control system. |
Lines Added |
Lines added to files for the selected dimensions. |
Lines Deleted |
Total number of deleted lines. |
Lines Modified |
Total number of changed lines in the time period selected. |
Total Churn |
Total churn in the code, computed as: [Lines Added] + [Lines Deleted] + [Lines Modified]. |
Total Lines |
Total number of lines in the selected part of the file path hierarchy at the point of a specific build or across a set of builds. This calculation only returns information for builds, and will return NULL when you use it without selecting individual builds. The number of lines is calculated by aggregating the lines added and lines deleted that have contributed to a specific build type/operating system combination. |
Dimensions
The following table describes the attributes that are included in the Build perspective. You can aggregate the measures along each of these attributes.
Attribute |
Dimension |
Description |
---|---|---|
Build |
Build |
Number or name used to uniquely identify the build. |
Build Start Time |
Build |
Date and time the build began. |
Build Type |
Build |
Name of the build definition. For more information, see How to: Create a Build Definition. |
Changeset |
Changeset |
The check-in comment associated with the changeset. |
Changeset ID |
Changeset |
The Changeset Name or ID which included the file changes. |
Policy Override Comment |
Changeset |
The comment that is provided when a policy is overridden. If a policy was not overridden with this changeset, this field is null. |
Alias |
Checked In By |
The alias of the person checking in the code modifications. |
Person |
Checked In By |
The user name of the person checking in the code modifications. |
Year Month Date |
Date |
The date on which the changeset was submitted organized by year, month and date. |
Year Week Date |
Date |
The date on which the changeset was submitted organized by year, week of the year and date. |
Date |
Date |
The date on which the changeset was submitted. |
File Extension |
Filename |
The type of file (file name extension) for which the changes were made. |
File Path |
Filename |
A hierarchy of the directories and files in the source control database. |
Team Project |
Team Project |
The name of the team project. |
ID |
Work Item |
The work item's ID, as assigned when the work item was created. |
Previous State |
Work Item |
The previous state of the work item. |
Work Item Type |
Work Item |
The type of the work item. |
Reason |
Work Item |
The reason that the state of the work item changed. |
Rev |
Work Item |
The revision of the work item. |
State |
Work Item |
The state of the work item. |
Title |
Work Item |
The title of the work item. |
(other) |
Work Item |
Other attributes depending on the process template used to create the team project. For more information, see the "The Work Item Dimension" section of Current Work Item Perspective. |