TfsBuild.rsp and Logging Verbosity in Orcas

In the 2.0 .NET Framework, MSBuild’s default verbosity for its FileLogger was “normal”.  As such, if you needed diagnostic logging information in a Team Build build (e.g. for debugging an issue with the build process) you needed to add the following to your TfsBuild.rsp file:


-or more briefly-


In the 3.5 .NET Framework, lots of things have changed with respect to the MSBuild file logger.  First of all, the default verbosity for the FileLogger is now “diagnostic” rather than “normal”.  Secondly, the FileLogger now has its own command-line options – /fileLogger (/fl) turns on file logging, while /fileLoggerParameters (/flp) is used to pass parameters into the file logger.  So – to set logging versobity back to normal in a Team Build build in Orcas (e.g. when you are not debugging an issue with the build process and want to keep your log files small) you will need to add the following to your TfsBuild.rsp file:


-or more briefly-


Another thing you may notice if you look closely is that Team Build no longer passes too many options to MSBuild directly through the command-line.  Instead, we dynamically generate a new copy of TfsBuild.rsp that contains the standard Team Build options followed by whatever you have in your checked in TfsBuild.rsp (if anything).  As such, a typical TfsBuild.rsp file on a build machine might look something like this:

### Begin Team Build Generated Arguments ###

/dl:BuildLogger,<BuildLogger Assembly>;<BuildLogger Parameters>
/fl /flp:logfile=BuildLog.txt;encoding=Unicode;
/p:TeamBuildRefPath=”C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies”


### End Team Build Generated Arguments ###

### Begin Checked In TfsBuild.rsp Arguments ###

# This is a response file for MSBuild
# Add custom MSBuild command line options in this file


### End Checked In TfsBuild.rsp Arguments ###

Again, if you look carefully here you may notice the /m:4 option at the top of the sample rsp file.  This has to do with MSBuild 3.5’s new multi-process feature – more on this in a subsequent post!

Comments (4)

  1. Brian Harry on All Orcas Beta 1 downloads are now available. Tan on Resuming Conflict Resolution in Team…

  2. A while back I had a post on the modified command-line options for file logging in MSBuild in the 3.5

  3. mikeycooper says:

    Aaron, this solved my problem with buildlog.txt being enormous after a team build.  Thanks!  I still have an issue where the number of build steps generated for multiple solutions has blown out from several hundred in TFS 2005 to 3500+ in TFS 2008.  Do you know if there’s some way yet to turn down the verbosity of what gets logged as a  build step?

  4. TFS : Control the verbosity of the logging during the build