What is a Source Control Binding?

If you've ever used the Change Source Control feature in Visual Studio .NET 2003 when disconnecting from the network or when branching a project or solution, you've come face to face with a source control binding.

Today, I'll expand on a post I made last Tuesday (Guidance on Creating Projects and Solutions) in an attempt to better explain the concept of a source control binding.  In that post I wrote, "When you add the solution and initial project to source control, the SCC provider does not differentiate between the project and solution--and this is the important part--because the initial project file (*.*proj) and the solution file (*.sln) occupy the same folder on disk. Therefore, the source control provider creates a single binding for both containers. Internally, we discuss solutions and projects in terms of bindings, or connections between the working copy of a project or solution and its master copy under source control. You may recognize these words, which appear in Visual Studio's Change Source Control dialog."

To be a little more clear, a source control binding is like a data line through which a connection between your working copy of a source-controlled solution and its master copy in the database can be established.

You can think of a well-formed (defined below), source-controlled, multi-project solution as a house with multiple rooms. When you build the house, you install a single highspeed data line from one room to the street. Inside the house, you install a router behind a firewall to distribute the data feed to other rooms and you pay an Internet service provider to connect your house to the Internet.

In Visual Studio .NET, that single data line is a source control binding. When you open a source-controlled solution, a connection is created across that binding which establishes a handshake between your working copy of the solution on disk and the master copy of the solution in the source control database.

Conversely, a source-controlled, multi-project solution that is not well-formed is like a house in which every room is connected to the Internet directly. Internet charges are more expensive than in the single-connection house, maintenance costs are higher, and switching to a different Internet service provider is much more difficult and time consuming.

Just as in the house with a single connection to the Interent, it's better to have a solution and all of its projects share a single source control binding. You can create well-formed, multi-project, single-binding solutions by creating a blank solution as outlined in Guidance on Creating Projects and Solutions. You can also do so by selecting the Create Directory for Solution option in the New Project dialog box when creating a solution-project pair.

Single-binding solutions are easier to:

·         Disconnect from source control in order to work offline.

·         Connect to the database after reconnecting to the network.

·         Branch in one step.

++++++++++++++++++++++++++++++++++++++++++++++++++++

This posting is provided "AS IS" with no warranties, and confers no rights. Microsoft kann für die Richtigkeit und Vollständigkeit der Inhalte in dieser Newsgroup keine Haftung übernehmen. Este mensaje se proporciona "como está" sin garantías de ninguna clase, y no otorga ningún derecho.

Published 20 August 03 06:02 by KorbyP

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# Keith Hill said on August 29, 2003 5:17 PM:
A bit OT but do you know why VS.NET SCCI can't handle renaming projects once they are checked into a SCM system (ClearCase is what I am using)? To do this, I have to exit VS.NET, rename the .csproj.* files and then check out the SLN file and update the name there and check it in. It sure would be nice if the VS.NET SCCI could just handle this for me.
# Chloe-Vervier said on October 4, 2003 7:57 PM:
I just want to say THANKS to all people in this community. You really help me.
# hgh age said on January 6, 2004 3:48 PM:
A little late but I want to wish you a good luck in this year Happy New Year
# MindFill - Brian Carroll's Blog said on March 9, 2004 3:39 PM:
# rosy.zhang said on May 12, 2005 3:25 AM:
Hey,when I open the multi-project solution B in Visual Studio 2003,which is branched from solution A that The source control bindings for project in VSS,a box with message "The source control bindings for project differ from those stored in the solution file. Both sets of bindings must be the same."When I click
"Don't change anything",it could run properly.When I click to use "Solution's binding" or "Project's binding" and check in ,the same box pops up next time.And I don't meet such problem in solution A.How to solve this problem?
# Igor said on June 13, 2006 9:32 PM:
Korby, you definetely have a talent explaining simple things in a complex way.
# replicarolex said on September 15, 2006 8:18 PM:
[URL=http://http://replicarolexwatch.ir.pl]replica-rolex-watch[/URL]<a href="http://http://replicarolexwatch.ir.pl">replica rolex watch</a>

Leave a Comment

(required) 
(optional)
(required) 

Search

Go

This Blog

Syndication

Page view tracker