Previously I’ve blogged about how to create a TFS Performance Heat Map using Excel 2007. This is great for a once-off look, but it requires you to update the data source and re-apply the conditional formatting every time a new daily column gets added.
The TFS Performance Heat Map report allows TFS administrators, users and IT Operations staff to monitor the performance of TFS commands and answer questions like “Is CheckIn slower today than yesterday?”
I’ve created a reporting services version of the same data, which allows you to export to PDF and setup a subscription to have it emailed to you daily. I followed the SSW Rules to Better SQL Reporting Services 2005 to give it that professional touch. Thanks to fellow Team System MVP Adam Cogan for the tip!
Here’s an example of what the PDF version looks like:
I’ve made the Visual Studio 2005 solution available which includes two projects. A C# assembly for doing the Heat Map colour calculations and a SQL Reports project. You will need SQL 2005 Business Intelligence Studio installed to be able to open that project. The zip file includes everything necessary to deploy the report manually without these tools though.
Manual Report Deployment
To deploy the report manually, these are the basic steps:
- Extract the contents of the ZIP file to your server
- Setup a new or existing service account (TFSREPORTS) with data-reader access to the TfsActivityLogging database
- Open ‘Performance Heat Map.rdl’ and change the timezone offsets to match your timezone. (see below)
- Open http://your-server/Reports
- Select ‘Upload File’ and choose ‘Performance Heat Map.rdl’
- Select ‘New Data Source’ (see below)
- Select ‘Properties’ of the report
- Select ‘Data Sources’
- Select the data source that you just created
- Apply the changes
- Deploy the Utilities DLL (see below)
- View the report
Changing the Timezone
In the SQL query that I use, I convert all the StartTime dates from their GMT times their local times. I also set all the command times to 12:00 midnight, so that the grouping works correctly.
The report is currently configured for GMT+11 (Australian Eastern Standard Daylight Time).
- Open ‘Performance Heat Map.rdl’ in notepad
- Do a Find/Replace on “DATEADD(hh, 11, StartTime)” and replace +11 with your offset. e.g. “-8″ for PST
In my next revision, I’ll change this to a hidden parameter or something.
Create a new Report Data Source
If you’re not using Visual Studio 2005 to deploy the report, then you will need to manually create an appropriate data source. The settings you’ll need are:
- Connection String: Data Source=SERVER-NAME;Initial Catalog=TfsActivityLogging
This probably shouldn’t be an actual user’s account. You might be better off specifically granting the DOMAIN\TFSREPORTS service account access to the TfsActivityLogging database and using that.
Once you’ve created the data source, you will need to point the report at it.
Deploying the Heat Map calculation assembly
To calculate the different gradients of colours, I’ve used a custom .NET assembly based on the code from Andrew Fryer’s blog post. For Reporting Services to be able to access this assembly, it must be copied to the server.
To use it in the report designer, you need to copy it to:
C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\PrivateAssemblies
To make it available for reports that have been deployed to the report server, you need to copy it to:
C:\Program Files\Microsoft SQL Server\MSSQL.3\Reporting Services\ReportServer\bin
I hope you find this useful, please leave a comment if you do. I’ve got some ideas for more ‘operational’ reports to create.
7 Comments
Wow Grant! This is great and extremely useful. Thanks for making this available.
Ed B.
You rock! This is great.
Hi Grant, thanks heaps for this. Two things though.
Firstly, following the manual deployment process, I found that I needed to deploy the calculation utilities assembly before I was able to upload the rdl file.
Secondly, I assume that the query used is dependent upon TFS2008? I saw no mention of this in your post, so thought I’d try it out even tho we’re still on TFS ‘05.
To get the report working though, I found that I needed to change the query since it was dependent on a field “ExecutionCount”, which is not present in my ‘05 database. So, instead of using:
(SUM(ExecutionTime) / SUM(ExecutionCount))
to calculate Duration, I’ve used:
(SUM(ExecutionTime) / Count(*))
Does that sound right? The figures I’m getting look to be about what I’d expect so I think I’ve got it right…
Cheers
Mark L
I am adding this to my Foundation server daily operations reports. Great visability into what the server is actually doing.
I am new to SSRS and not a programmer. I am interested in the Heatmap example for my reporting needs. Where do you create the dll… in Visual Studio? Also, how do you reference the dll in your report?
Hi,
How I can decide standard values of commands sothat I can check my server is in within limits? Is ther any data for No. of projects?
Hi Grant,
I have been using your performance heat map report for a couple of months now and its a great tool to get some insight in the performance of my server. But now i have recently upgraded from SQL Server 2005 SP3 to SQL Server 2008 SP1. Now all the spaces are filled with a yellowish color, no heat map just yellow. Do i need to update the report somehow to work with SQL Server 2008?
Kind regards,
Jeroen Vos
One Trackback
[...] Grant Holliday on TFS Performance Heat Map Reporting Services Report. [...]