Does using Visual Studio with TFS require a persistent connection to TFS from VS? - visual-studio

I'm an IT project manager. A developer on my team is complaining that she keeps losing her connection to TFS and that VS requires a constant connection to TFS to work for her. Our CIO is asking me why she doesn't only need a connection to TFS while checking in and out code. I do not know the answer.
Thank you,
Val

TFVC, Team Foundation Version Control, is one of the ways to store sources in Team Foundation Server (TFS), if your TFS serves is 2015 or later, Git is the new default. TFVC is a centralized version control system and assumes your developer has a persistent connection to the server. This is especially true when the workspace of the developer is configured as a "server" workspace, in which case each file system operation is synced to the central server.
In Workspace Type = Server mode your options are:
Use the Go Offline option to temporarily disconnect from the server and work locally in isolation.
Of Change the workspace type to local, which creates a local folder with a compressed copy of each file in the workspace.
This will reduce the number of interactions with the server, making it more pleasant to work when authentication is messed up. But a developer should be checking in and out code at a regular interval, preferably each change that puts the code in a stable state. I'd get VERY frustrated when even something as a checkin/checkout requires an auth prompt.
But your real problem
Is not whether TFS is prompting for auth, it's why the workstation or the server infra isn't (allowing the) caching of the credentials. This can have many causes:
The TFS server isn't configured with a secure connection (https)
The TFS server name doesn't match the server configuration
A proxy server is interfering
A local development proxy (like Fiddler) is turned on and not configured to ignore the TFS server
The Active Directory policy is forcing the credentials to not be stored
The TPM of the computer isn't working well and keeps resetting
There is a VPN interfering
Some endpoint monitoring system is detecting suspicious behavior and is triggering a re-auth
An incorrect credential is cached in the Windows Credential Manager.
The TFS server is in the wrong internet security zone
The Internet security zone settings are configured to not store credentials
...
...
Solve that and the developer will be much happier.
And TFVC is getting old (and most teams have moved to Git)
As others already commented, TFVC is getting old and many development teams have migrated to Git. Git gives developers a local copy of the sources and its history to work with, giving much more power to the developers to work locally without a need to connect to a central server.
If migration isn't an option (yet), tools like git tfs can help a developer to start working in Git locally, while still connecting to a central TFVC server to send the changes to the rest of the team.
But the long-term solution is to upgrade your development tools and get rid of TFVC.
TFS is getting old (is now Azure DevOps Server)
And while you're at it, TFS is getting old. It has been renamed in 2018 and is now called Azure DevOps Server. Azure DevOps Server 2020 is the latest. If you're having issues with TFS, making sure it's up to date and installed on a recent Windows Server version helps too.

Related

Cannot connect TFS

I want to connect to TFS through the Team Explorer in Visual Studio 2015.
So, my problem is that I cannot connect because of a wrong authentication (valid username and password, valid privileges).
I think the reason for that is the Domain but I never joined one because I use a normal version of Windows 10 Enterprise. Could it depend on installed features like WCF? I did really intensive research but I'm not able to find any information to solve my problem.
Here is a screenshot of the Login-Dialog:
On premise TFS only supports Windows auth (either local or domain).
If your TFS server and VS are installed on the same machine, you could use your local account with enough permission to connect TFS server directly.
If your TFS server and VS are installed on the different machine, and since you haven't joined domain. Suggest you to join domain : This is the easiest to setup, user-wise. All you have to do is be a member of the domain and a member in a team project. Another option is using Visual Studio Team Service (TFS in the cloud) for this. It's currently free and uses Microsoft live accounts instead. Which you can access it everywhere on the internet.
First I want to thank you for your support.
I'm sorry that this comes late but I already solved my problem.
I obviously just forgot to put a Backslash in front of my username so that I don't use the domain of my local computer.

Build Controller failing to start on TFS 2013 "Service cannot be started. The handle is invalid”

After cloning a 2010 TFS server, upgrading the clone's OS to 2012R2, upgrading SQL Server to 2012 SP2 (11.0.5343), uninstalling TFS 2010, and upgrading to TFS 2013 with update 5, we are running into issues starting the Build Service on the clone.
I've removed the agents and build controllers referencing the other original server through Manage Build Controllers, in Visual Studio 2013.
I've tried to use the TFS 2013 upgrade wizard and it fails when attempting to start the build service so I tried to unconfigure: "tfsconfig.exe setup /uninstall:TeamBuild" and reconfigure through the TFS 2013 upgrade wizard but it yielded the same result.
The TFS database server, Build Server, controller, and agent are located on the same box
For measure, I've even deleted the agents, controllers, and Unregistered and Registered the Build Service in the Team Foundation Server Administration Console as both the batch account used on the original server but that failed so to rule out authentication, I used my domain account (I'm a Local Admin, SQL Server Admin, and TFS Admin) but still had the same result with both accounts.
The Windows event log states “Service cannot be started. The handle is invalid”.
I'm not sure what else could be missed does anyone have any pointers?
There were over 100 Microsoft patches/updates applied over the weekend and the issue went away. Microsoft confirmed that the issue was related to the OS, not the TFS configuration or installation/upgrade.
Thanks for all your suggestions. Hopefully this will help someone else out if they are in the same situation and spinning wheels to find the answer. Keep your systems as up to date as possible!
Try to remove build service by going to Team Foundation Server Administration Console, select server name, and click Remove Feature, to remove build service feature, then re-configure it.

Issue while creating TFS Team Project

I’m doing a VSS to TFS upgrade for my team. We have configured the TFS server, now I’m trying to create a Team project on the server from my local VS2013 and I get an error as in the attached picture.
I have Farm administrator rights on SharePoint site, Full admin access to the Collection where I’m trying to create the Team project, Content Manager Rights on the Reports Folder.
I have cleared the TFS cache on my local as well.
Can you please help me out if I’m missing anything?
If you configured TFS to have Reports, it tries to create a folder in Reporting Services and populate with some pre-canned reports.
The error says that it is not able to find the machine with Reporting Services. Review the configuration at the console, if you can ping the machine, if port 80 (or another if you changed default) is reachable.

Source Server support on VMs with VMWare Lab Manager and TFS?

My company is interested in better integrating our investment in VMWare with our TFS deployment. Currently the company is running TFS2005 SP1, VS2010, and we have a sizeable SAN that we would like to use in environment reproduction similar to what is offered in TFS2010 Lab Management.
Of the features offered by TFS2005, we are currently leveraging only TF Version Control--work items and build automation are handled by separate systems. However, we would like to use the TFS-integrated Symbol/Source server in order to accurately debug the different versions of our product, and that's where we're running into difficulty.
The VMs deployed in VMWare are not joined to the corporate domain, and this means that we run into difficulty when attemping to grab source code information via Source Server and the "tf.exe view" command.
If devenv is run on the VM, it can't authenticate a domain account, and tf.exe view fails when grabbing source info.
If devenv is run on the developer desktop and debugging is done with remote debugger, the vm's local user account fails to access the share exposed by Symbol Server and can't load symbols to begin with, much less retrieve source.
Has anyone done this before?
Yes - You can still do this. If you are using Windows 7 (and I believe Windows Vista) you can always add the domain credentials to the "Credentials Manager" in the Control Panel. This will help it authenticate for the TFS URL whenever it needs to talk to TFS.
BTW, I have a blog post discussing the Symbol Server and Source Server features of TFS 2010 available here: http://bit.ly/SymbolServerTFS

Visual Studio with a Remote Server

The site that I am working on is at a remote server. I want to work on it locally. Are there any tools better then that in Visual Studio for working with a remote website?
Rather than deal with the quirkiness of VS remoting, what about using Remote Desktop to drive VS on a machine local to your target (behind VPN for example)?
If you can set up a subversion server on the remote site you could use that to sync changes between locations. This would be really helpful in other areas as well such as allowing multiple people to mess with your code and to keep track of every change you make. It would also be the best in the area of performance.
If its a windows share, just set up the repository where it is right now then use:
svn checkout file:///project/trunk
Or if its over a web server you can set up SVN to be served though that as well.
There are plenty of free/not free plugins for VS that make working with SVN very easy.

Resources