Part 1Setting up TFS Azure
Part 2Configuring Visual Studio to use TFS Azure
Part 3Registering Team Build controllers for TFS Azure
Part 4 

Introduction

Continuing from Part 2, now that we have the essentials set up, we’ll take a look at how to utilize the full functionality of Team Foundation Server Azure.

Before we get too deep into the article – this from Microsoft:

5. Unable to configure a TFS 2010 build agent/controller

Unfortunately, the TFS 2010 build agent and controller is not compatible with the Team Foundation Service Preview. You’ll need to use the build server software that is part of the Team Foundation Server 11 Developer Preview. You can find information about that release here.

You’ll need to install a facet of the Team Foundation Server 2011 Developer Preview in order to configure a Build Controller and Agents.

Microsoft® Visual Studio® Team Foundation Server 11 Developer Preview is the collaboration platform at the core of the Microsoft Application Lifecycle Management suite of tools, which helps teams be more agile, collaborate more effectively, and deliver better software faster.

Anyhow, you’ll have to download the installer (choose from Web Installer, .iso or self extracting EXE).  you could start downloading while continuing reading this article.

TFS Preview invite codes

I’ve had a few readers contact me in regards to invite codes for TFS Preview.  AFAIK, I was able to help them all out; and I have a couple of code/activations (2-3) left. 
So if you haven’t received your own activation code yet, and want to get started ASAP, drop me a line and I’ll send you one of the last codes I have which still has activations available.

Continuing Along

So when we left off, we’d configured Visual Studio 2010 to connect to TFS Azure, but now it is time to consume TFS Azure by using some of the functionality available.  I’ve got a sample solution that I’ll be writing about and publishing in a later series of posts, and I’ll be using it as a guinea pig (test) of TFS Azure’s service.

Open the solution you’d like to manage under TFS Azure, connect to your TFS Azure account (follow steps in Part 2), and then add your solution to Source Control as you would for a normal solution.  I prefer to add my solution structure to the source control directory before opening the solution.  This makes it easier to bind.

You can check your bindings, you should be able to bind:

binding

Now, once the solution is opened, you’ll see that the files are pending in the source control window:

source tree

As a good developer always does, I’ve run my Unit Tests and ensured that everything is peachy:

UnitTestsPass

Now that everything is ready, I’ll commit my changes to the Cloud!

commit

Assuming all goes well, you commit should work successfully, and your solution is now hosted and bound to TFS Azure.

Building

Configuring automated builds, however, pose a tougher problem to solve.  First, I tried to create a build definition myself, as I would with TFS 2010.  I navigated my way to the Team Explorer window and right clicked on Builds and tried to create a “New Build Definition”:

create build

This was met (predictably) with the following (somewhat unhelpful) error message:

“TF225001: Creating a build definition requires a build controller be defined for this team project collection.”

controller

As mentioned earlier, and according to this known issues page – you’ll need to install the Team Foundation Server 2011 Developer Preview to define build and a build controller.

So, whilst we’re sitting pretty without our solution bound to source control, we can’t create continuous integration or other automated build definitions.  A pickle.

Configuring a TFS 2011 Build Service

I’ll be the first to pose this question – what’s the point of Team Foundation Server Azure (in the Cloud) if build controllers and build agents don’t also sit in the cloud?  It seems totally redundant to me, to go to the hassle of binding to Azure if I must create and maintain my own build controller and agents in what amounts to off-cloud hosting.

It is my hope that this is rectified sooner or later.

Nonetheless, moving on..

To set up a build controller/agent you can follow along here, watch Richard Hundhausen’s video or read BHarry’s post here.

Install

Once you’ve downloaded and mounted the TFS 2011 Developer Preview image, you’ll need to run the TFS Server install.  I realise that a separate installer for the build parts would be *far* more convenient, but you have no choice in the matter, it seems:

install

Once the variety of prerequisites are preinstalled (including the ominous copying  of installers to the dreaded “installer cache” you’ll be prompted with the following screen:

image

Configure Your Build Server

Since we’re only interested in the Build Service, select it from the left hand tree, and then click on “Start Wizard”.

Once you hit the welcome page, click “Next” ton configure your Build Service installation.  On the second page you’ll have to select your Team Collection, you do this in much the same way as from Team Explorer (refer to Part 2 for details).

imageimage

image

Once connected, you’ll notice that there are no build controllers.

Clicking Next, we’ll accept the default, and have a build controller and single build agent created for us.

image

image

On the next page, we’ll be prompted to provide credentials for the Build Service to run under.  Note that you can change the default port that the service will use to communicate with TFS Azure (9191 by default).  You might want to ensure you’ve opened the port with your firewall (or other systems).  Don’t forget to click on the “Test” hyperlink to authenticate the credentials you’ve supplied.

Also note that the service will use the Windows Live credentials you specified when you connected to the Team Collection, earlier in the configuration steps, not the credentials you specify now, to connect to TFS Azure.

image

Our final page is the configuration summary page.  Once satisfied that your configuration is correct, press the Next button:

imageimage

Once the checks have completed, click on the “Configure” button..

imageimage

Once finished, you should get (hopefully) all successes.  Your Build Controller is now registered with your TFS Azure account.

image

Finally – A Build Configuration

Now that we’ve configured a Build Controller.. we can return to Visual Studio 2010.  I refreshed my Team Explorer, then right clicked on the Build item and selected “New Build Definition”.  This time, a different result – success.

imageimage

Now I can configure my build as I normally would.  For my first build, I’m not going to bother with a drop folder, so I unchecked this option (above) and also in the Process configuration:

image

Building

Now I’ve saved my build configuration, I’m going to run a test build.  I right click on the build definition and select “Queue New Build”:

image

image

My initial build built, but failed the unit testing.  This was caused by one of the tests which launches an interactive WinForm.  Commenting out this form, and checking in, triggers the automatic Continuous Integration build.  With luck, everything passes the second time:

imageimage

Returning to our browser, if you log into your TFS console, ensuring you aren’t in the Administration section, you can browse and see the build history now:

image

Conclusion

TFS Azure represents a tantalizing option for teams to share their workspaces and automated builds, but until Build Controllers and Build Agents can be hosted in the Cloud too, build services are a major weakness.   It is also somewhat disappointing that the Build Server software isn’t packaged and made available as a separate installation package (less than 1 GB).

That said, I had no trouble at all in configuring the Build Service 2011 (Developer Preview) and the whole process from Visual Studio 2010 to TFS Azure to Team Build worked seamlessly the first time through, with no errors or installation show stoppers.

In the next article, we’ll look at some ways we can customize the build as well as set some more meta data, such as Areas/Iterations and team security settings.  We’ll also look at how we can link build definitions into our work items and how the registered builds play a part in our overall SDLC.

Check out http://www.tfspreview.com for more information, or the community message boards located here.

Part 1Setting up TFS Azure
Part 2Configuring Visual Studio to use TFS Azure
Part 3Registering Team Build controllers for TFS Azure
Part 4 
 

Introduction

Recently I had to determine a universal product versioning syntax for our products and services.   This was done to ensure a level of consistency between projects and products. Depending on the deployment, currently there has been a wildly different format used between products and services.  

Given the recent adoption of Team Foundation Server 2010 (TFS), and the use of Team Build throughout the product and service range, the new numbering format and branching strategy is designed to support the functionality TFS provides.

Methodology

The cardinal rule of build and release management is: “each build must be unique”.  Without the ability to discern one build from another, a team cannot establish any baselines; nor can issues or defects be reported on, or resolved in, a specific (identifiable) release candidate.

To ensure every build is unique, every product or service release will be identified following a basic numbering format: [Major].[Minor].[Build].[Revision].  In addition to binary numbering (which accompanies files built as part of the build process), the build is identified also by the Build Configuration Name – the name and number form the unique build name within systems such as Team Foundation Server. 

Note that Continuous Integration builds do not require an increment in version number (to avoid a useless increase in the signal-to-noise ratio of build numbers registered in TFS).

image

[Major], [Minor]

The project management team for each project will define the [major] and [minor] numbers for each release in line with project goals and the addition of features and functionality etc. Typically a production release will involve a minor number increment, although should the changes warrant it, a major revision is also likely.

[Build Number]

The [build] number is an atomically increasing number which ensures the uniqueness of each release build and label. Note that CI builds should not increment the product number. Formal builds also create a label within source control, so that the exact source can always be retrieved at any point in the future.

[Revision Number]

The [revision] number should be incremented in the event of a rebuild e.g. due to a build failure or perhaps because a build doesn’t pass smoke testing (and needs to be fixed and rebuilt). The revision number should be reset to zero once the build is accepted.

Note that TFS 2010 uses build labels throughout work items in each Team Project (for example in Bug work items) so that work items can be tied to explicit builds which have been created. These, in turn, can also be linked to automation run executions, changesets, work items and so on.

[The Build Name]

Thus our standard production build will be represented by the following naming convention:

<[Build Configuration Name +  Number(Maj.Min.Build.Rev)]> Example: Widget Release Build [1.0.0.0]

Understanding Source Control

The standard approach to source control management has solutions arrayed in a specific folder structure, often defined as follows:

image

The following definitions are applied:

RootThe top level folder in a folder hierarchy
TrunkRepresents the main, ongoing development of a solution (or solutions)
BranchesTypically represents forks in the source control management, usually branched from the trunk

There are several different valid approaches to source control branching and without going into detail, the most common are:

  • Branch per Release
    • Branch contains a specific product release build
    • Useful for patching production releases
  • Code-Promotion Branches
    • Specific code can be isolated for specific testing
    • Useful for feature isolation development
    • Reduces instances of source file conflicts
  • Branch per Task
    • Rather than branching by feature, code can be isolated according to a specific task, such as vertical architecture changes (e.g. cross cutting concerns)
    • Branch per Component
    • For larger projects, individual components may be branched for independent development and release
  • Branch per Technology
    • Useful when dealing with multiple operating platforms or versions, development can be split in alignment with different technology alignment, or environments

Generally, these approaches stem from a rationale behind change isolation – i.e. reducing the impact of change on the development of a solution’s code base.  To learn more about these branching strategies, refer to the “Further Reading” section below.

Branching and Versioning Scenarios

The following are diagrams and scenarios which outline our approach to product and release versioning under branching scenarios.

Versioning Branches

Since our approach to release management dictates a unique build number per release, and typically an increment in the Major or Minor build number, we may branch source control at any time, continuing the product numbering in parallel.

This means that there may be concurrent builds of a solution with a similar – if not identical – version, differentiated by the build configuration/build definition naming.

When a release candidate is produced – and ultimately put into production – the remaining branches (or trunk, as applicable) are then incremented (typically with the minor version) so that ongoing development now represents the next logical product number.

Persisting Version Numbers

Anytime a Branch is merged back into the Trunk, the version number of the Trunk is persisted, not the branch version. The Branch can be resurrected at any time in the future, by branching from the merge change set.

If a Branch is merged into another Branch, typically the version number of the target Branch is kept.

A Release Versioning Example

Prior to release:

Trunk: 1.2.345.0
Branch A: 1.2.358.0 (branched from 1.2.298.0)
Branch B: 1.2.349.0

After a release from Trunk:

Trunk: 1.3.345.0 [Released as 1.2.346.0]
Branch A: 1.3.358.0 (branched from 1.2.298.0)
Branch B: 1.3.349.0

After a release from Branch A:

Trunk: 1.4.355.0 (branch A merged and released as 1.2.354.0 from the Trunk)
Branch B: 1.4.361.0

Patching

One of the most common scenarios involves patching a released product. Whilst normal development has continued on (on the source control trunk), a branch is created from the released code base, patched, and then the new updated release is deployed to production.

image

A Common Patching/Branching Scenario

Feature Isolation

Below you may observe two different approaches (labelled as options A and B) which can be undertaken to support “feature” branch releases – one scenario avoids a trunk release (option B); both are valid options no matter how many branches exist in parallel – they just require multiple source file merges.

image

In this scenario, the feature branch doesn’t feature the release patch until the final merge to trunk, prior to release

image

In this scenario, the release is made from the branch, then merged into the trunk

In general, it is considered a “best practice” to merge changes to the trunk and release as this avoids potential merges with other branches, and also means rolling changes can be included in other releases. It’s also far less messy in the long run.

Multiple Branch Releases

It is also possible to release and merge concurrent branches, although this carries a fairly large overhead, requiring merging of three (or more) different revisions of files. This has been captured in the following scenario:

image

In this scenario, Branches A and B are merged to the Trunk before being released

Additionally, rather than releasing from the Trunk, it is also possible to merge two branches into a “feature release branch”, prior to merging down to the Trunk. This is captured in the following scenario:

image

This release contains a “feature merge” branch, combining the changes from Branch A and B

Further Reading

Chris Birmele’s Branching and Merging Primer
http://msdn.microsoft.com/en-us/library/aa730834%28VS.80%29.aspx

 
Part 1Setting up TFS Azure
Part 2Configuring Visual Studio to use TFS Azure
Part 3Registering Team Build controllers for TFS Azure
Part 4 

Introduction

Continuing on from Part 1, we’re taking an early look at TFS Azure, Microsoft’s first service offering of Team Foundation Server backed on top of the Azure Cloud service.

The Continuing Saga

By now you have probably registered with TFSPreview.com and created an initial Team Project.  Using the same Windows Live credentials, now we’ll look at connecting to and consuming resources from Visual Studio 2010.

I’m assuming that you already have Team Explorer installed (if not, you’ll need it) and that you’ve applied Visual Studio 2010  Service Pack 1 and the KB Hotfix.  I encountered a plethora of issues getting the hotfix applied, but hopefully you will have had less issues.

Connecting and Authenticating

Start Visual Studio 2010 and, once loaded, go to Team (Menu) –> Connect to Team Foundation Server.

Since this it the first time you’ll be connecting, click on the Servers.. button, and then click on the add button in the next dialog.  Use the URI listed on your TFSPreview administration page (in the form .tfspreview.com">.tfspreview.com">.tfspreview.com">.tfspreview.com">https://<yoursite>.tfspreview.com):

image image

If all goes well, you’ll get an authentication page pop up and ask you to select the federated security model of choice (as of writing, only Live IDs are supported).

Selecting the default provider, we’re taking to Live to sign in – use the same credentials you registered your TFS service with (for best results).  You can create or assign other IDs later on.

Once authentication is complete, you should find your server has been successfully added to the list of TFS servers.  Select your server and you should be prompted with the available Team Projects:

image image

Victory is Mine

Once opened, Team Explorer should populate as if the TFS service was not cloud based, which means we should be able to use TFS more or less as we would normally, i.e. source control, work items etc..

image image

Limitations

A few things to note, from my first glance:

  • No Team Portal (SharePoint) or Team Web Access
  • Team Members (from TFS Power Tools) doesn’t seem to work/populate
  • No Reporting (SSRS)
  • No Process Guidance
  • Can’t create a new Team Project from inside Visual Studio:

image

    • You’ll need to create Team Projects from the browser/admin site
  • Group Membership/Security is managed via the website, even if you use the context menu in Visual Studio

Next Steps

In the next part, we’ll add a sample solution and define a build controller, and define a build definition or three, and see how well TFS responds.  We’ll also allocate some extra users, and play with permissions, groups and work items.

Part 1Setting up TFS Azure
Part 2Configuring Visual Studio to use TFS Azure
Part 3Registering Team Build controllers for TFS Azure
Part 4 
 

Introduction

At the recent BUILD convention in the US, Microsoft announced a series of new Cloud-based services, one in particular being Team Foundation Server.  Although we’ve heard rumours about such an offering for a long time, and that some services (such as TFSNow) actually were offered by third parties, this represents the first major push from Microsoft directly.

In order to drum up some initial interest, Microsoft launched http://www.tfspreview.com and an early beta period with invites sent to BUILD attendees and select members of the Microsoft development community.  Although there are already a spate of blogs with video and image walkthroughs, I decided to give TFS Preview the Sanders Technology treatment.

I’ve been building or administering TFS installations for over six years now, since the early betas of Team Foundation Server 2005 back when I was an Associate Consultant at Readify.  I’ve deep experience in all versions of TFS to date, so I expect I’m in a decent position to evaluate and discuss this new service and how it integrates into the development process.

Let’s start at the beginning..

Signing Up

Before we go any further.. have you got an invite code?  They are rather hard to come by, and a lot of the early multi-use codes are now exhausted.  I, personally, have a few activations left on an invite code (or two) so to those lucky readers who get in first, I’m happy to email you a TFS Preview invite code while I can – while stocks last!

Once you have your invite code, browse to http://www.tfspreview.com and click on the “Create Account” button.

image image

On the next page, select a name for your TFS URL, paste your invite code and agree to the ToS.  You’ll need a valid Live Account (which is used for all valid users of TFS in the cloud).

Assuming it all goes smoothly, your account will be created, and you’ll appear at the main console page.  What to do next, is to examine all your software and make sure you have applied the hotfix (for Visual Studio 2010) if you wish to get your hands dirty.  However, there’s still some initial configuration to be done in your browser first.

Creating a Team Project

image

Everything in TFS revolves around a Collection and a Team Project.  In normal TFS, you can have multiple collections and multiple Team Projects – in the cloud, it seems that we have just the default collection (if anyone can figure out how to create multiple, please let me know).

From the account page, click on the “Administration” link in the upper right hand corner of the screen.  You’ll enter the Administration console which has a number of options: 

image

Our immediate priority is to create a Team Project – clicking on “create team project” will provide us with this nifty pop up window – fill in the details as you desire, and proceed by clicking on “Create Project”:

image

Administration

Once the project has been successfully created, you’ll also notice that a default collection has been created, and your team project is now a child of that default collection.  The console now provides more functionality – click on the Project drop list and select “Browse all Projects”:

image

Select your Team Project and then click “Navigate”.  I’ve circled the main page navigation as each should be worthy of a bit of investigation.  Each link provides access to security, group membership and key team project configuration (such as Areas and Iterations) which essentially represent their approximate siblings in TFS 2005, 2008 and 2010 respectively.  Little has changed here, except that instead of adding Active Directory accounts to groups, you add users according to their Live Accounts instead.

image

From the main page you can view all the traditional options which we would find in Team Foundation Server, I’ve taken screen captures of the most interesting windows:

image image
Areas                                                     Iterations

image image
Security                                                 Group Membership

image image
Member Details                                      Project Groups

By default, the user who creates the Team Project is an administrator, which means complete access to all settings and functionality.  Now that a Team Project has been created, you will want to consume TFS from within Visual Studio.

If you haven’t already, download and install the hotfix located here.  When I ran the hotfix I received this:

image

If you hit a wall, probably best to reapply Visual Studio 2010 Service Pack 1.  Last of all, you can also hit the TFS Azure forums which are located here: http://social.msdn.microsoft.com/Forums/en-US/TFService/threads

Check back son for Part 2, where we’ll look at some practical ways to use this new TFS cloud service!

Downloads

Software Downloads for the Team Foundation Service Preview:
http://blogs.msdn.com/b/visualstudioalm/archive/2011/09/14/tfs-preview-downloads.aspx

Microsoft® Visual Studio® 11 Developer Preview:
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=27542

 

Not too long ago I wrote an article about Team Foundation Server licensing.  Now that it is 2011, and after some recent access requests for TFS, I’ve decided it is time for an update.

Does TFS cover SQL Server Licensing?

One instance of Microsoft SQL Server 2008 Standard Edition or SQL Server 2008 R2 Standard Edition can be used as the Team Foundation Server 2010 database.

That’s right – TFS 2010 includes a Standard Edition license for SQL Server but only when used exclusively as the data store for TFS and nothing else.  The paper doesn’t stipulate if the license is only valid for single tier or dual tier configurations, but since the database instance must be used exclusively by TFS, I can’t see why it wouldn’t cover dual tier deployments.  Note that if you want to use a different version of SQL (Enterprise, DataCenter) you need a separate license.

How about TFS user licensing?

A few years ago, Microsoft eased up a little bit on the licensing restrictions which caused a user to require a Client Access License (which are expensive).  The clause in the TFS licensing is explicitly:

Client Access License Exception for Certain Work Items
A user does not need a CAL or External Connector License to create new work items or to update work items that that same user has created. This exception applies only to work items related to defect filing or enhancement requests. However, a CAL is required when a user views or modifies a work item created by another user or interacts with Team Foundation Server in any other way.

Which opens up TFS for people who wish to create defects (bugs) and feature requests.  Accessing TFS for this purpose is fairly obvious and easy to open to a large host of users – via Web Access.  However, how does a TFS Administrator set permissions appropriately?  It turns out that, via the TFS Administration Console, Active Directory groups and users can be added to a special group called the “Work Item Only View Users”.  For more information on configuring this, see the following article: Work Item Only View (WIOV) Users in TFS 2010

Members of the Work Item Only View Users group are restricted to a limited view, which is indicated by the “Work Item Only View” tag in the top right hand corner of the web application page:

image

By default, I noticed that restricted use users did not automatically have permissions to create work items!  This rendered the whole exercise rather pointless.  Digging deeper, I realised I’d have to grant permissions on a per-Team Project basis so that the limited permission group could create work items.  Given that each Team Project could have a different template base, I believe you’ll also have to grant permissions separately for work item types as well – where the work item type relates to a defect or enhancement.

Note that external users (users who do not belong to the parent organization) are required to be licensed both with a CAL (if working beyond the scope of the CAL exception) and an External Connector License (which is a nice way of raising some extra revenue).

I can think of ways around that licensing model..

Now, don’t think that “multiplexing” or pooling access to TFS will avoid the need for CALS for your users!

End users or devices that access Team Foundation Server in any way-other than the Client Access License Exception for Certain Work Items exception noted above-are required to have the appropriate licenses, regardless of whether they are using a direct or indirect connection to the software.

Which translates into: “no matter how a user accesses TFS or TFS data, Microsoft want their money”.  Even automated builds aren’t devoid of licensing creep.  An automated deployment or build which does basically anything other than compile requires a Visual Studio license:

CAL Requirements for Builds
Users who merely execute and review builds are only required to have a Team Foundation Server CAL; however, users who author tests or other types of validation and include them as part of a build must be licensed for the appropriate Visual Studio 2010 individual development tool.

This extends to the execution of: unit tests, code coverage tests, web or load testing, architectural tests (validations) or any code analysis or coded UI or database unit testing.

Also note that the following shows the many ways TFS can be accessed:

Accessing Team Foundation Server
The Team Foundation Server 2010 data can be accessed in several ways, including:

  • Visual Studio Team Explorer 2010, which is included with Visual Studio 2010 Ultimate, Visual Studio 2010 Premium, Visual Studio 2010 Professional, and Visual Studio Test Professional 2010, and available for download to the general public. Team Explorer also can be installed as a standalone client, and on as many physical devices as you like.
  • Visual Studio Team Web Access 2010, which is a browser-based version of the Team Explorer client.
  • Microsoft Office ExcelR or Microsoft Office Project, which can access Team Foundation Server using add-ins for those programs that are provided with Team Explorer.
  • Microsoft Expression Blend. 3, which can access Team Foundation Server without requiring Team Explorer.
  • Microsoft Expression Studio 4 (all editions), which can access Team Foundation Server without requiring Team Explorer.
  • Programmatically, as enabled through the Team Foundation Server 2010 application programming interfaces (APIs) or by other means.

For more information, why not check out the whitepaper directly?  See below for further reading.

Visual Studio

Further Reading

Visual Studio 2010 and MSDN Licensing White Paper
Work Item Only View (WIOV) Users in TFS 2010
Team Foundation Server Permissions
Visual Studio 2010 and MSDN Licensing White Paper (updated)


F8S7T93JTXQR

 

Our environment is interesting.

For a variety of reasons, the Development, QA, Integration and UAT environments have been partitioned from the Corporate AD forest for a long time.  This year we’re attempting to move Development, QA, UAT and Integration into one new AD forest to simplify management of the server and network resources.

We’re also deploying Team Foundation Server 2010.  The prerequisite was to use the existing Microsoft Office SharePoint Server (2010) which has been deployed in the Corporate forest.  Lastly, the new domain has a one way trust to the Corporate AD forest (which is administered by a professional hosting and support company), which means that anyone in the Technology team can authenticate to the Development domain.

Initially, I tried to run TFS 2010 from within the Development domain, integrated with SharePoint 2010 in the Corporate forest.  This ended up working with about 95% of functionality; I had TFS working with Corporate domain based service accounts, and the only thing broken were the TFS dashboard templates (Excel Workbook reports mainly) which needed to authenticate to the Report Server in the Development AD forest.

It dawned on me that this was simply not feasible arrangement, despite my best efforts.  It also presented an awkward administration perspective, since tools such as TFS Administrator couldn’t reconcile Security Groups I’d created in the Development forest for grouping Corporate users into “TFS User” groupings (e.g. Contributors, Project Managers, Administrators at a broad level).

We discussed the drawbacks of migrating SharePoint 2010 into the Development forest (I was, and remain, adamant that we needed a simplified administration model for TFS and related resources) until it was pointed out that there was another option.  Running TFS 2010 in the Corporate forest.  This hinged on us being delegated an OU (Organizational Unit) in the Corporate forest, so that we could create and administer service accounts and management (security) groups of our own.

image

This is the option we went with, and it is working like a charm. 

Users belong to the Corporate domain, which allows them integration with all the company assets (like payroll, timesheets, mail), but also to reuse the same credentials when accessing work items, source control, build environments and development server resources.  The Team Build server sits in the Development forest and can communicate with the TFS server, it is running with Corporate forest service credentials – and can deploy deeper into the Development forest resources.

Anyhow, this is a work in progress.  In the next week or so we will be migrating new and current applications and services and also performing upgrades to convert the solutions into Visual Studio 2010 compatible solutions.  This is more pain and learning, but should start to build the basis for a more unified and consistent development environment.

 

If you’ve ever wanted to have an installation of Team Foundation Server 2010 use a standalone or existing instance of SharePoint Server (2010) then you’ve likely needed to install Extensions for SharePoint on the MOSS server.  If, like me, you encountered the following error whilst trying to configure the extensions – you might be able to fix the problem like I did.

The error recorded in the (unhelpful) installation log is:

!Verify Error!: TF250002: No content Web applications exist in this Web farm. You must create a new SharePoint Web application in SharePoint Central Administration.

Now, I’d read and re-read the installation guide.  Heck, I’d ever read the troubleshooting guide (attached here for your convenience).  I got so frustrated I tried to manually install the WSP files myself from this blog entry [1].  It resulted in the following message:

Object reference not set to an instance of an object. Microsoft.TeamFoundation.SharePoint.Dashboards.wsp: The Solution installation failed.

Time for some sanity checks.  Make sure the account you are trying to install/configure the Extensions with is a local Administrator.  Also ensure the account is a member of the Farm Administrators group in SharePoint Central Administration.

Lastly – the kicker – make sure your account has access to the MOSS Database!  I found when I searched through the Application log in the machine’s Event Log, that there was an entry (Source = SharePoint Foundation) notifying that:

SQL database login for ‘SharePoint_Config’ on instance ‘<instance>’ failed. Additional error information from SQL Server is included below.

Login failed for user ‘<my user account>’.

So the moral of the story is that you must ensure that the account you install from has the following permissions:

  • Local Administrator
  • Member of the Farm Administrators group in SharePoint
  • Appropriate permissions to access the SharePoint configuration database

You can also follow this handy installation guide [2] which has proved very helpful.

Bon Appetit!

[1] https://msmvps.com/blogs/vstsblog/archive/2011/01/13/how-to-manually-install-tfs-extensions-for-sharepoint.aspx

[2] http://blog.hinshelwood.com/archive/2010/05/03/integrate-sharepoint-2010-with-team-foundation-server-2010.aspx

Troubleshooting Guide

 

If you use Team Explorer (or the TFS client components) and have to configure to connect using a proxy, you might find yourself a little stumped. 

Fortunately for us former Readify and current Microsoft TFS guru Grant Holliday provides excellent insight into how to solve this problem, via Stack Overflow.

If you just want to configure your client to use a proxy server, there is no property to do this. You have to set a registry key or an undocumented environment variable.

For TFS2008 clients, the registry key is: [HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\9.0\TeamFoundation\SourceControl\Proxy]
"Enabled"="True"
"Url"="http://someproxy:8081"

For TFS2010 clients, the registry key is: [HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\10.0\TeamFoundation\SourceControl\Proxy]
"Enabled"="True"
"Url"="http://someproxy:8081"

In either TFS version, you can set the undocumented environment variable:

System.Environment.
SetEnvironmentVariable("TFSPROXY",http://someproxy:8081);

Here’s Grant’s original answer on Stack Overflow (up vote if it helped you!).

 

Somewhat hot off the press comes word that the September 2010 release of Microsoft’s Team Foundation Server Power Tools has hit the Internet.  If you are into installing some great add-ins for Visual Studio you might also want to take a look at the Productivity Power Tools for Visual Studio 2010 as well.

From the release notes for TFS Power Tools:

Team Foundation Server 2010 Power Tools

This release supports Visual Studio Team Foundation Server 2010. The following table provides links to access more information about each power tool included in this release.

Alerts Explorer

A plug-in to Visual Studio, Alerts Explorer provides a graphical user interface that supports flexible subscription of alerts based on check-in, work item change, or build completion.

Team Foundation Server Backups

New! The tool can schedule backups for the following databases that your deployment of Team Foundation Server uses:

  • the configuration database
  • the database for each team project collection
  • the databases that Team Foundation Server uses in conjunction with SharePoint Products, if your deployment includes integration with SharePoint Products
  • the databases that Team Foundation Server uses in conjunction with SQL Server Reporting Services, if your deployment includes reports

By using the restore wizard included with this tool, you can restore your entire deployment to new hardware, or selectively restore team project collections to an earlier point in time.

Microsoft Team Foundation Server 2010 Best Practices Analyzer

To launch the Microsoft Team Foundation Server 2010 Best Practices Analyzer, click Start, point to All Programs, point to Microsoft Team Foundation Server 2010 Power Tools, point to Microsoft Visual Studio Best Practices Analyzer, and then click TfsBpa.exe.

Updated! A diagnostic tool with a graphical user interface that you can use to perform the following actions:

  • Verify that the deployment for Team Foundation Server is configured according to recommended best practices
  • Identify the source of problems in an unhealthy deployment.
  • Take a snapshot of the configuration of a deployment.
  • Obtain usage data about the volume of data stored or accessed in the past 14 days. Includes specific information about database tables that have a tendency to grow and that may need to be reduced in size.

Custom Check-in Policy Pack

A supplemental set of four custom check-in policies to use to enforce software development practices during the check-in process.

Process Editor

An add-in to the Tools menu, the Process Editor provides a graphical user interface for editing Team Foundation Server process templates inside the Visual Studio IDE. This tool also provides a GUI for viewing the values assigned to all fields defined in a project collection.

Team Explorer Enhancements

Updated! This tool provides additional Visual Studio menu options and functions to support finding files under version control by status or wildcard, opening a folder using Windows Explorer from the Source Control Explorer context menu, and labeling files and folders in Source Control Explorer.

Team Foundation Power Tool (TFPT.EXE) Tool

Updated! A command line tool that you can use to work with files and directories under version control, team projects, and work items. Some commands display a graphical user interface when run.

Team Members

An add-in to Team Explorer, this tool allows you to organize users into sub-teams and access a number of collaborative tools, such as IM and email, sharing of queries and links, and downloading and installation of custom Team Foundation components.

Windows PowerShell Cmdlets for Visual Studio Team System Team Foundation Server

This tool provides a Windows PowerShell interface that supports basic version control commands and a pipeline and glue to enable scripting.

Windows Shell Extensions

This tool provides integration with Windows Explorer and the common file dialogs. With this integration, you can perform many source control operations without having to run Visual Studio or a Team Foundation command-line tool.

Work Item Templates

This tool provides an add-in to the Team menu and a folder under each team project node in Team Explorer. With this tool, you can create, apply, capture, set, and organize default work item templates.

As for the productivity power tools, which are something new for me admittedly, there looks to be some excellent new functionality.  Check back with me in a couple of weeks and I’ll add some feedback about what I’ve found to be generally the more useful features.

Visual Studio 2010 Productivity Power Tools

A set of extensions to Visual Studio Professional (and above) which improves developer productivity. In this second major release of the Power Tools we have added the following four extensions:

Tools Options Support

The number one feature request by far has been the ability to turn off the individual extensions in the Productivity Power Tools.  In this release, we’ve added an extension which adds a category to Tools Options which allows you to toggle the extensions on/off and provides a single place to find the options for a particular extension.


Solution Navigator  (More Info)

Solution Navigator is a new tool window that acts like an enhanced Solution Explorer.  With it, you can:

  • Expand code files to navigate to its classes, expand classes to navigate to their members, and so on (C# and VB only)
  • Search your solution, all the way down to class members
  • Filter your solution or projects to see just opened files, unsaved files, and so on
  • View related information about classes and members (such as references or callers/callees for C#)
  • Preview images by hovering over them, or preview rich information by hovering over code ite

In other words, it merges functionality from Solution Explorer, Class View, Object Browser, Call Hierarchy, Navigate To, and Find Symbol References all into one tool window!
Note that the tool window doesn’t (yet) support everything that Solution Explorer supports, such as multiselect and drag-and-drop.
Solution Navigator also provides interactive tooltips in C# and VB code (replacing the default “quick info” tooltips) that give you the same kind of data, but right at your fingertips.  In addition to getting the tooltips on hover, you can:

  • Press Ctrl+1 to open a relevant tooltip at the current cursor location
  • Press Ctrl+2 to quickly navigate to any class/member in the current source file


Quick Access  (More Info)

Quick Access is a new tool window that allows users to search for and execute common tasks within the Visual Studio IDE.  Not sure where a particular menu command is located?  Want a quick way to create a new Silverlight project? By using Quick Access, you can efficiently find and execute common VS operations without taking your hands off the keyboard.  Quick Access allows users to:

  • Execute Main Menu and Context Menu commands
  • Open the New Project Dialog with a specific Project Template selected
  • Show a tool window
  • Jump to a Visual Studio Options page
  • Navigate to an open document in your Tab Well
  • Create and execute a series of actions (task)  


To use, press Ctrl+3 to launch Quick Access, type in your search term (e.g., “debug”), and press Enter on the desired result.  If your search term returns too many results, continue pressing Ctrl+3 to cycle through each category of results.

Auto Brace Completion

Automatic Brace Completion improves the productivity of writing code by automatically inserting the closing code construct when the opening construct is typed for VB & C#.  More specifically, this extension:

  • Supports the following constructs: (), {}, [], <>, “”, and ‘’. 
  • Allows you to press <TAB> to navigate past the next enclosing brace
  • Allows you to automatically complete a statement in C# by inserting the closing semi-colon and moving you to the next line with SHIFT + ENTER

The extensions from the previous Producitivity Power Tools have been included and improved. See the revision notes at the end of this post:

Tab Well UI  (More Info)

This extension allows you to completely customize the behaviour of your document tabs from the Productivity Power Tools Options:

  • Scrollable tabs
    Maintain spatial consistency of the documents that are included in the document well.
  • Vertical tabs
    Document tabs are shown vertically, allowing you to fit more tabs than are normally visible when shown horizontally.
  • Pinned tabs
    Allows you to pin tabs to keep them always visible and available.
  • Show close button in tab well
    Similar to Visual Studio 2008, will show a close button in the document well that will close the active tab.
  • Tab Behavior
    • Remove tabs by usage order (LRU)
      When a new tab is inserted and existing tabs don’t fit in the document well, instead of removing the tab at the end of the well it will remove the least recently used tab. This ensures that frequently used tabs are readily available.
    • Show pinned tabs in a separate row/column
      Pinning tabs can quickly cause you to run out of space for regular tabs. The option allows you to always show pinned tabs in a separate row (or column, if displayed vertically) from regular tabs.
    • Sorting
      • Sort tabs by project
        Tabs will be sorted by the project they belong to, thus keeping them always together in the document tab well.
      • Sort tabs alphabetically
        Tabs will be sorted alphabetically. When Sort By Project is turned on, tabs will be sorted first by project and then alphabetically.
      • Sort tab well dropdown alphabetically
        The drop down menu at the right end of the document well is sorted alphabetically. This option allows ordering as the tabs are laid out in the document well.
  • Tab UI
    • Color tabs according to their project or according to regular expressions
      This option permits tabs to be colored according to the project they belong to. This is particularly useful when sorting tabs by project, as it allows you to immediately identify different groups of project documents.
      You can also configure regular expressions and assign a color to each one. If the name of a tab matches the configured regular expression, it will be colored with the assigned color.
  • Miscellaneous options that modify tab UI
    • Show document/toolwindow icon in tab
    • Show close button in tab
    • Modify dirty indicator style
      This option allows you to select from a set of different dirty indicators that you might prefer over the asterisk.
    • Modify minimum and maximum tab size
      Allows you to modify minimum and maximum tab size. Try setting minimum and maximum sizes to the same value, and you will have evenly spaced tabs.

Searchable Add Reference Dialog (More Info)

The new Add Reference dialog makes it faster and easier for you to find the reference that you are looking for and add it to your VB, C# or F# project.  From the Solution Explorer, simply right click on the References node, select the Add Reference command to see the updated Add Reference Dialog.

Highlight Current Line

As the resolution of monitors increases, it’s becoming more difficult to find the caret in the code editor.  The highlight current line extension makes it easy to find the caret by highlighting the line that the caret is on in the editor.  You can even configure the default colour by changing the setting for “Current Line (Extension)” and “Current Line Inactive (Extension)” in Tools Options Fonts & Colors.

HTML Copy (More Info)

This extension provides support for the HTML Clipboard format when cutting or copying code from the editor.  This means that you’ll no longer have to go fix up the formatting of your code when you paste it into a TFS bug form or any other HTML based control.

Triple Click

It’s never been easier to select a line of code from the mouse by simple triple-clicking anywhere on the line.

Fix Mixed Tabs

Some developers prefer tabs, others prefer spaces, and nobody likes mixing tabs & spaces.  This extension promotes developer harmony by warning as they are open or save a file that has a mixture of tabs & spaces.  The information bar also provides an easy way to fix the file to suit your preference.

Ctrl + Click Go To Definition

This extension gives the editor a web browser by adding clickable hyperlinks to symbols in your code as you hold down the Ctrl key.

Align Assignments

This extension is useful for making your code a little more readable by aligning the assignments when you type Ctrl+Alt+] such that it takes this:

And turns it into this:

Please note: This may conflict with your formatting settings. E.g. in C# you will need to disable: Tools->Options->Text Editor->C#->Formatting->Spacing->"Ignore spaces in declaration statements"

Move Line Up/Down Commands

This extension maps the Alt+Up Arrow & Alt+Down Arrow keys such that they will move the current line of code or the selected lines up and down through the editor.

Column Guides

Since Visual Studio 2002, there has been a not so secret registry key which allowed user to draw a vertical line in the code editor.  This is very useful to remind developers that their full line of code or comments may not fit one a single screen. Thanks to this extension this feature has returned with UI configure it.  Simply place the cursor at the appropriate column and select Add Guideline from the context menu 

Colorized Parameter Help

This extension improves consistency with the editor by applying syntax highlighting to the contents of the Parameter Help window for C# &VB.
Please note: Syntax highlighting colors can be customized using the display items prefixed with “Signature Help” in the “Fonts and Colors” menu.

These are worth downloading and can be very, very good time savers.  If you have been using Team Foundation Server without TFS Power Tools, what have you been waiting for?  Go install now :)

 

Hot off the press – a release of the much anticipated Power Tools for Visual Studio/Team Foundation Server 2010 – April 2010 (RTM).  This release enables some of my favourite TFS goodness including:

  • Alerts Explorer,
  • Microsoft Team Foundation Server 2010 Best Practices Analyzer,
  • Custom Check-in Policy Pack,
  • Process Editor,
  • Team Explorer Enhancements*,
  • Team Foundation Power Tool (TFPT.EXE) Tool,
  • Team Members,
  • Windows PowerShell Cmdlets for Visual Studio Team System Team Foundation Server

and my favourite, Windows Shell integration**. 

What are you waiting for?  Go grab it!

* This tool provides additional Visual Studio menu options and functions to support finding files under version control by status or wildcard, opening a folder using
  Windows Explorer from the Source Control Explorer context menu, and labelling files and folders in Source Control Explorer.
 

** This tool provides integration with Windows Explorer and the common file dialogs. With this integration, you can perform many source control operations without having to
   run Visual Studio or a Team Foundation command-line tool.

[1] http://visualstudiogallery.msdn.microsoft.com/en-us/3e8c9b68-6e39-4577-b9b7-78489b5cb1da

Aussie Wine Guy


© 2012 Rob Sanders: Sanders Technology Suffusion theme by Sayontan Sinha
WordPress SEO fine-tune by Meta SEO Pack from Poradnik Webmastera