Quantcast
Channel: Team Foundation Server - General forum
Viewing all 6687 articles
Browse latest View live

Locating Source Control Foder in Team Foundation Server.

$
0
0

Hi all,

I am new to Team Foundation Server 2013. I have installed & configured Team Foundation Server 2013 in my lab environment and created team project collection and team project & also configured the Workspace.

I workspace there are two paths.

Local Path:- It is easily understandable it is the local path where the source code is stored. I am able to locate it from my

team foundation server client machine.

Source Location:- I am not able to locate this location in the Team foundation Server. This location starts with '$' sign for example ($/SIMAProject). When I tried to locate this location in the machine where TFS 2013 in installed, i did not find it.

Can you please tell me how to find this location in the server.

Thanks,

Vishwajeet.


Creating Build Definition with MSbuild files

TFS 2012 - how to easily find AreaID of Areas ?

$
0
0

We need to easily get the AreaID value, for each Team that we create under a Team Project.Can u please specify a simple recommended way to get it ?

We can create a dummy work item, associate with the Area of the Team, and then run a Query in TFS web-access that shows the Area and its AreaID value within the result. But this is somewhat crude since it require dummy work items, which need to be deleted afterwards...

TFS 2012 error using MSSCCI plugin

$
0
0

When trying to add a file to source control using MSSCCI plugin with National Instruments Labwindows CVI and TestStand the following message is displayed:

Could not load file or assembly

'Microsoft.TeamFoundation.VersionControl.ControlAdapter, Version=11.0.0.0,

Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.

Invalid pointer (Exception from HRESULT:0x80004003 (E_POINTER))

Any help in resolving this issue would be much appreciated!

Thanks!

TFS (Visual Studio Team Foundation Server), does it come with a copy of Visual Studio?

$
0
0
Does Visual Studio Team Foundation Server come with a copy of Visual Studio?

TFS path length limitations - workaround?

$
0
0

We ran into this issue over a year ago when a Build process failed because of it. The max file path length accepted is around 260 characters and that is easy to bump into
especially with multiple nested directories I was looking at our TFS Source
code container the other day noticed folders such as "Release" and
"R". I asked what "R" was? It is our current attempt to shrink the lengths of all folders to avoid the 260 character limit. Similar butchering is evident in other folder names. My response was "TINA" ("This Is Not Acceptable")<o:p></o:p>

Has this issue been fixed in TFS 2012? Are there any Microsoft workarounds?

TIA,

edm2



TF215097 - Could not load file or assembly 'Microsoft.TeamFoundation.WorkItemTracking.Client, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.

$
0
0

Just finished with an in place upgrade of our TFS Build Machine from 2012 to to 2013. VS2013 and VS2012 are both installed on that box now.   When I queue  one of our previous build definitions, we see the following build error.  What causes this error and how do we prevent?

Exception Message: Could not load file or assembly 'Microsoft.TeamFoundation.WorkItemTracking.Client, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) (type FileLoadException)
Exception Stack Trace:    at System.Reflection.RuntimeAssembly.GetType(RuntimeAssembly assembly, String name, Boolean throwOnError, Boolean ignoreCase, ObjectHandleOnStack type)
   at System.Reflection.RuntimeAssembly.GetType(String name, Boolean throwOnError, Boolean ignoreCase)
   at System.Xaml.Schema.XamlNamespace.SearchAssembliesForShortName(String shortName)
   at System.Xaml.Schema.XamlNamespace.TryGetType(String typeName)
   at System.Xaml.Schema.XamlNamespace.GetXamlType(String typeName, XamlType[] typeArgs)
   at System.Xaml.XamlSchemaContext.GetXamlType(String xamlNamespace, String name, XamlType[] typeArguments)
   at System.Activities.XamlIntegration.ActivityXamlServices.DynamicActivityReaderSchemaContext.GetXamlType(String xamlNamespace, String name, XamlType[] typeArguments)
   at MS.Internal.Xaml.XamlContext.GetXamlType(XamlTypeName typeName, Boolean returnUnknownTypesOnFailure, Boolean skipVisibilityCheck)
   at MS.Internal.Xaml.Parser.XamlScanner.ReadObjectElement_Object(String xmlns, String name, XamlScannerNode node)
   at MS.Internal.Xaml.Parser.XamlScanner.ReadObjectElement(XamlName name, Boolean isEmptyTag)
   at MS.Internal.Xaml.Parser.XamlScanner.DoXmlRead()
   at MS.Internal.Xaml.Parser.XamlScanner.Read()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyContent>d__5f.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_NonemptyPropertyElement>d__42.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyElement>d__35.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyContent>d__5f.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_NonemptyPropertyElement>d__42.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyElement>d__35.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyContent>d__5f.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_NonemptyPropertyElement>d__42.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyElement>d__35.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyContent>d__5f.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_NonemptyPropertyElement>d__42.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyElement>d__35.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyContent>d__5f.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_NonemptyPropertyElement>d__42.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_PropertyElement>d__35.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementContent>d__4a.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_ElementBody>d__23.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<P_Element>d__7.MoveNext()
   at MS.Internal.Xaml.Parser.XamlPullParser.<Parse>d__0.MoveNext()
   at MS.Internal.Xaml.NodeStreamSorter.ReadAheadToEndOfAttributes()
   at MS.Internal.Xaml.NodeStreamSorter.ReadAheadAndSortCtorProperties()
   at MS.Internal.Xaml.NodeStreamSorter.MoveNext()
   at System.Xaml.XamlXmlReader.Read()
   at System.Activities.XamlIntegration.DynamicActivityXamlReader.Read()
   at System.Xaml.XamlServices.Transform(XamlReader xamlReader, XamlWriter xamlWriter, Boolean closeWriter)
   at System.Xaml.XamlServices.Load(XamlReader xamlReader)
   at System.Activities.XamlIntegration.ActivityXamlServices.Load(XamlReader xamlReader, ActivityXamlServicesSettings settings)
   at System.Activities.XamlIntegration.ActivityXamlServices.Load(XmlReader xmlReader, ActivityXamlServicesSettings settings)
   at Microsoft.TeamFoundation.Build.Workflow.WorkflowHelpers.DeserializeWorkflow(String markup, Boolean throwException, List`1& assemblyMismatches)
   at Microsoft.TeamFoundation.Build.Hosting.BuildProcessCache.LoadFromXaml(String workflowXaml, TextExpressionImports textExpressionImports)
   at Microsoft.TeamFoundation.Build.Hosting.BuildControllerWorkflowManager.PrepareRequestForBuild(WorkflowManagerActivity activity, IBuildDetail build, WorkflowRequest request, IDictionary`2 dataContext)
   at Microsoft.TeamFoundation.Build.Hosting.BuildWorkflowManager.TryStartWorkflow(WorkflowRequest request, WorkflowManagerActivity activity, BuildWorkflowInstance& workflowInstance, Exception& error, Boolean& syncLockTaken)

TFS build template upgrade?

$
0
0

When upgrading from TFS 2012 to TFS 2013, is the default build template automatically upgraded so that our existing build definitions get it automatically or is there some manual step involved?


TFS 2013 interop / TFS 2012 interop?

$
0
0

Our IT upgraded our main TFS server from 2012 to 2013 but did not upgrade the build server (separate machine) from 2012 to 2013.  It seems like everything still builds just fine though.  Are there any gotchas or missing features in this scenario (main TFS server = 2013, build server = 2012).  What are the steps required to update the build server portion of TFS?

Agile or Scrum or CMMI

$
0
0

Hi,

We are going to use TFS 2013.

Process templates -scrum,agile,cnmi

My question which 1 is the best to go for.

General Question:

And also i have seen articles like agile scrum .

is both are same?what is the difference between?.

Please answer my questions

Thanks


priyanka


Build multiple solution configurations using one TFS build definition

$
0
0

Hello,

I have 2 solutions, one contains Managed C# code and other having C++ code. The Managed code is built using the "Any CPU" configuration, while the C++ solution is platform dependent i.e. x86 or x64. 

I would like to create one TFS build definition to build both solutions, each for it's own respective configuration. However, I could not do that easily using the UI as the TFS build does not allow me to select individual configurations for each solution. 

I was wondering if this is possible. 

Really appreciate your help in advance. 

Thanks,
Ashwin

Visual Studio 2013

TFS 2010


Licence in Team Foundation Server

$
0
0

HI

We bought vs2013 with tfs.

I know that i can use Microsoft cloud for free in less then 5 users in the tfs.

I would like to know more about the terms please.

Thank you

Danny

TFS 2013 plugin error: TF30059: Fatal error while initializing web service

$
0
0

Hi,

I have develop a plugin in TFS 2010 use ISubscriber process events to do some action when a work item is changed. It was working fine in TFS 2010. Then we have move it to TFS 2012 and it was working fine there. but after migrating to TFS 2013, it does not work any more.

I tried almost everything. Compile with latest dll for 2013, put the VisualStudio.service.common.dll file and recompile etc. but didn't found a solution. when i change some work items or try to connect to TFS, it gives me following error:

Please contact your administrator. There was an error contacting the server.
Technical information (for administrator):
  HTTP code 500: Internal Server Error

Looking at the logs in event viewer it throws following exception:

TF53010: The following error has occurred in a Team Foundation component or extension:
Date (UTC): 7/14/2014 1:43:44 PM
Machine: RND-TFS2013
Application Domain: /LM/W3SVC/2/ROOT/tfs-14-130498190190213468
Assembly: Microsoft.TeamFoundation.Framework.Server, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a; v4.0.30319
Service Host:
Process Details:
  Process Name: w3wp
  Process Id: 4840
  Thread Id: 4728
  Account name: NT AUTHORITY\NETWORK SERVICE

Detailed Message: TF30059: Fatal error while initializing web service

Web Request Details
    Url: http://mytfserver:8080/tfs/DefaultCollection/Services/v1.0/TeamConfigurationService.asmx [method: POST]
    User Agent: Team Foundation (devenv.exe, 12.0.21005.1, TE, SKU:14)
    Headers: Connection=Keep-Alive&Content-Length=359&Content-Type=application%2fsoap%2bxml%3b+charset%3dutf-8&Accept-Encoding=gzip&Accept-Language=en-US&Expect=100-continue&Host=rnd-tfs2013%3a8080&User-Agent=Team+Foundation+(devenv.exe%2c+12.0.21005.1%2c+TE%2c+SKU%3a14)&X-TFS-Version=1.0.0.0&X-TFS-Session=e485c555-8eee-4e0b-a8d0-9854ecb3625b%2c+GetTeamConfigurationsForUser&X-VSS-Agent=TFS%3a+b1a8d5f0-6650-4f08-931c-004721f26a5f&SOAPAction=%22http%3a%2f%2fschemas.microsoft.com%2fTeamFoundation%2f2005%2f06%2fServices%2fTeamConfiguration%2f01%2fGetTeamConfigurationsForUser%22
    Path: /tfs/DefaultCollection/Services/v1.0/TeamConfigurationService.asmx
    Local Request: True
    Host Address: fe80::418d:cf6a:7d6d:656f%12
    User: not available [authentication type: not available]

Exception Message: A route named 'Location:ConnectionData' is already in the route collection. Route names must be unique.
Parameter name: name (type ArgumentException)
Exception Stack Trace:    at Microsoft.TeamFoundation.Framework.Server.TeamFoundationApplicationCore.ApplicationStart()
   at Microsoft.TeamFoundation.Framework.Server.TeamFoundationModule.Module_BeginRequest(Object sender, EventArgs e)

can anyone knows about this?

Replace DatabasaName with variables while checking in the code into TFS using VS

$
0
0

Hi,

I have created a variable DB_Test in a database project in VS. Whenever I make changes in the Database objects (like views & Stored procs) I do a schema compare using database as source and project as target and then update teh changes. The objects in TFS have the variable for referring to the DB (e.g., [$(DB_Test)].[dbo].[tblTest]) and after I update the TFS code using the database code the variable gets overwritten by the databasaname mentioned in the database. So, every time I update the code in TFS using schema compare, I will have to manually replace the database names in TFS with variable so that when I deploy from TFS into the database of another environment I could change the variable accordingy before publish.

I would like to know if there is a way where the VS itself replaces all the database names with variable references if already defined in the project?

Thanks,Vamsi

.

Good books to start with Microsoft Team Foundation Server

$
0
0

Hello guys,

I would like to ask for some book recommendations to learn about the Microsoft Team Foundation Server. You must know, my company is currently about to change our complete software development equipment. In fact, we are emigrating from Bugzilla as issue tracking system, SVN as Version Control System, TICOS as time recording software... etc. Everything will be combined into this giant beast called TFS.
Don't get me wrong. As always, I am excited to have the chance to learn something new about Microsoft products, because they are just everywhere. So it’s more like a natural science to study them, and thus really worth to invest time. I am really looking forward to get familiar with our new TFS system, but I realized pretty quickly that this will be a greater task which is not done by some googling, but rather needs a more fundamental approach.

As you can see, I don’t need any informations about the server-side part. Neither about TFS administration or setup, nor about the installation process.
What is important for me, are informations about its usage from the point of view of a software developer. Mainly via the Visual Studio Team Explorer as well as through the TFS web interface.
What is possible? What can be done? How to manage a project. How to open, manage and close requirements, work items, bug descriptions, change requests, test cases etc. How to manage, lock, unlock, update, commit, diff, branch and merge my repositories. How to link source code check-in’s to specific tasks. What kind of logs are written and how to view them.
Just, what does a software engineer need to know about TFS?

And, of course, my company did not include any time for training or training courses in our time schedule to learn about all these things. So I don't have time to read thousands of pages of a reference type of book. What I really need are compact informations from someone who knows what he’s talking about.

Can anyone suggest me some good books to achieve this?


Yours sincerely,

Michael


Quickest Way to Delete Large Project

$
0
0

What is the quickest way to delete a project from a project collection?

We split our large (1.3TB) project collection which had about 66 projects including one large (260GB) project into two collections. Everything went fine deleting the smaller (up to 30GB) projects until we got to the largest one.

The deletion process would fail via the GUI and tfsdelete command even after increasing the timeout to 10 hours! When we increased the timeout (we did so gradually - initially to 30 min then 4 hours and ultimately 10) it failed with the following message on version control:

[00:40:17.757] ++ Executing - Operation: ProjectDelete, Group: ProjectDelete.TfsSourceControl
[00:40:17.757] +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
[00:40:17.757] Executing step: Delete the team project data from Version Control
[00:40:17.757]   Executing step: 'Delete the team project data from Version Control' VersionControl.DeleteTeamProject (2 of 11)
[01:40:21.473]   [Error] TF246018: The database operation exceeded the timeout limit and has been cancelled. Verify that the parameters of the operation are correct.
[01:40:21.647]   Microsoft.TeamFoundation.Framework.Server.DatabaseOperationTimeoutException: TF246018: The database operation exceeded the timeout limit and has been cancelled. Verify that the parameters of the operation are correct. ---> System.Data.SqlClient.SqlException: Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding. ---> System.ComponentModel.Win32Exception: The wait operation timed out

Thanks in advance!


VB.Net Method appears to be called multiple times when it actually isn't, and returns inconsistent results

$
0
0

I have been staring at this problem all day and I'm completely baffled by what I'm seeing. There are two issues occurring, and unfortunately, one of them only happens in Production so I can't test it the way I'd like.

I will give all the background and relevant information up front with the code at the end. Some of what I say in these next couple sections won't make much sense until you review the code.

Background info:
(I have triple verified all this information)

  1. This class is being called from a TFS 2010 WWF build template. It relies on a library I've created in another tool to deploy files to our Universe environment using UniDK
  2. The deployment itself is working fine, the problem is with the logging and return codes.
  3. The build is marked as "Success" if the class below returns a code of 0, "Partial Success" with a return code of 1, and "Failed" if there is any other return code.
  4. The files are only being deployed one time (objDeploy.DeployFiles() is only called once)
  5. serverInfo.ServerCount = 2
  6. serverInfo.ServerActive for the second environment (counter = 1) is False
  7. To help track down the issues, I have added additional logging in ProcessResults() to output the values of the different collections to a separate file, but I haven't had an opportunity to run it with the additional code

Symptoms:

  1. In Production, it is exiting with a return code of 1 (exitCode = 1)
  2. This is what is returned by the results string:

Results for server name
Deployment successful! 
******************* 
Results for server name
Deployment successful! 
******************* 
Results for server name
Deployment errors, please review the log 
******************* 
Results for server name
Deployment successful! 
******************* 
Results for server name
Deployment successful! 
******************* 
3. In QA, we have the "results for server name" message 6 times, but each time says the deployment is successful
4. Everything in the deployment log file shows that all files deployed returned with a code of 0 (This means that Result40Collection, BackupErrorCollection, and BadErrorCollection should be empty. I will explain in a moment why this is especially significant)

What I expect to happen:

  1. exitCode = 0
  2. Build = succeeded
  3. results:

Results for server name
Deployment successful! 
******************* 

What I expect to happen based on the results in the TFS build log: 

In this section, I'm ignoring the fact that there are multiple entries being returned and only focusing on the one that says there were errors

  1. exitCode = 2
  2. Build = Failed
  3. results:

Results for server name
Deployment errors, please review the log 
******************* 

Code:

Imports System
Imports Microsoft.TeamFoundation.Build.Client
Imports System.Activities
Imports RMUtilities<BuildActivity(HostEnvironmentOption.All)>
Public NotInheritable Class DeployU2Files
    Inherits CodeActivity

#Region "Arguments"

    ' In Arguments
    Property inServerDataSet As InArgument(Of DataSet)  ' Dataset containing the server information
    Property inSourcesDirectory As InArgument(Of String)  ' Full path to the Source directory being deployed
    Property inBuildName As InArgument(Of String) ' Name of the build, to be used for backups
    Property inLogDirectory As InArgument(Of String) ' Path to the log folder

    ' Out Arguments
    Property outExitCode As OutArgument(Of Integer) ' Resulting error code, 0 is good
    Property outResult As OutArgument(Of String)     ' Result string

#End Region ' "Arguments"

#Region "Variables"

    ' Variables passed in from the build
    Dim dsServerDataSet As DataSet
    Dim strSourcesDirectory As String
    Dim strBuildName As String
    Dim strLogDirectory As String

    ' Variables used by the build
    Dim serverInfo As XMLReader
    Dim fileList As U2FileListParser

    ' Result variables
    Dim exitCode As Integer = 0
    Dim results As String = ""

#End Region '"Variables"

    Protected Overrides Sub Execute(context As System.Activities.CodeActivityContext)

        ' Sets the working variables
        dsServerDataSet = context.GetValue(Me.inServerDataSet)
        strSourcesDirectory = context.GetValue(Me.inSourcesDirectory)
        strBuildName = context.GetValue(Me.inBuildName)
        strLogDirectory = context.GetValue(Me.inLogDirectory)

        ' Creates the base objects needed for the deployment
        Try
            serverInfo = New XMLReader(dsServerDataSet)
            fileList = New U2FileListParser(strSourcesDirectory)
        Catch ex As NullReferenceException
            Throw New NullReferenceException("Invalid XML Dataset", ex)
            Exit Sub
        Catch ex As Exception
            Throw New Exception("Error processing file list: " & ex.Message, ex)
        End Try

        ' First, determine if there are files to deploy
        Dim fileCount As Integer
        Try
            With fileList
                fileCount = .DeployList.Count + .PreDeployList.Count + .PostDeployList.Count
            End With
        Catch ex As Exception
            Throw New ArgumentException("No files to deploy")
        End Try
        If fileCount = 0 Then Throw New ArgumentException("No files to deploy")

        ' Then, check to make sure there are servers to deploy to
        If serverInfo.ServerCount = 0 Then
            Throw New ArgumentException("No servers listed in XML file to deploy to")
        End If

        ' Iterates through each server in the XML file
        For counter = 0 To serverInfo.ServerCount - 1

            ' Sets the current environment
            serverInfo.ChosenEnvironment = counter

            ' Checks to make sure the server is active.  If it isn't, it's skipped
            If serverInfo.ServerActive Then

                ' Creates new logging object to log all output to a file with the name of the server being deployed to
                Dim logger = New RMLogging(strLogDirectory & "\" & serverInfo.ServerHostName & ".log")
                logger.Header = "Automated deploy" & vbCrLf & _"Build Number: " & strBuildName & vbCrLf & _"Date: " & DateTime.Now.ToString("MMM ddd d yyyy hh:mm:ss tt")

                ' Creates the deployment object
                Dim objDeploy As New U2Deploy(serverInfo, fileList, logger, strBuildName)

                ' Deploys the files to the environment, then checks the results to make sure they
                objDeploy.DeployFiles()

                ' This will determine the success level of the deployment, and also parses the message for the log
                ProcessResults(objDeploy, serverInfo.ServerHostName)

                ' If there was a problem writing the log, then add the full text of the log to the results
                If objDeploy.FullLog.Length > 0 Then
                    results &= objDeploy.FullLog & vbCrLf
                    results &= "**********************************" & vbCrLf
                End If ' objDeploy.FullLog.Length > 0

                ' Disposes the objects
                logger = Nothing
                objDeploy.Clear()
                objDeploy = Nothing

            End If ' serverInfo.ServerActive

        Next ' counter = 0 To serverInfo.ServerCount - 1

        SetResults(exitCode, results, context)

    End Sub

    ''' <summary>
    ''' Will change the exite code based on the results of the deployment
    ''' </summary>
    ''' <param name="objDeploy">U2Deploy object that contains the collections</param>
    ''' <remarks></remarks>
    Private Sub ProcessResults(objDeploy As U2Deploy, serverName As String)

        Dim currentErrorCode As Integer = 0


        results &= "Results for " & serverName & vbCrLf

        If objDeploy.Result40Collection.Count() > 0 Then
            currentErrorCode = 1
            results &= "Type 40 errors, please review the log" & vbCrLf
        End If ' objDeploy.Result40Collection.Count() > 0

        If objDeploy.BackupErrorCollection.Count > 0 Then
            currentErrorCode = 1
            results &= "File backup errors, please review the log" & vbCrLf
        End If ' objDeploy.BackupErrorCollection.Count > 0

        If objDeploy.BadErrorCollection.Count > 0 Then
            currentErrorCode = 2
            results &= "Deployment errors, please review the log" & vbCrLf
        End If

        If currentErrorCode = 0 Then results &= "Deployment successful!" & vbCrLf

        results &= "***********************" & vbCrLf

        If currentErrorCode > exitCode Then exitCode = currentErrorCode
    End Sub

    ' Sets the outgoing message and exit code.  This is used by the workflow to add messages to the buld itself
    Private Sub SetResults(ByVal exitCode As Int32, message As String, ByRef context As CodeActivityContext)

        context.SetValue(Me.outExitCode, exitCode)
        context.SetValue(Me.outResult, message)

    End Sub
End Class

Michael Wheway Software Release Specialist, PMSI

Test Attachment Cleaner

$
0
0

Hello,

I am facing some problem with Test Attachment Cleaner, Our production database of TFS started growing really big. To check the test attachment cleaner, i created similar environment in our testlab.

We have TFS 2013 Update 2 App Tier, The databas tier is SQL Server 2012 Enterprise. On my client machine, i have Visual Studio 2012 Update 4 installed. I installed the Team Foundation Server Administration kit on tried to run the TAC. It connects to the project, calculates the test attachments size. In Clean Test Attachment Section, I select the Configfile and click Start Clean, however even after running the script, when i test the test attachments via Microsoft Tet Manager, I do not see that the files are deleted. I check the database size, however it does not show me any reduction in database size as well, I wrote another config file still it did not work, Here is the config file which i made for the TAC Configfile

<DeletionCriteria>
  <TestRun>
    <AgeInDays OlderThan="30" NewerThan="999" />
  </TestRun>
  <Attachment>
     <Extensions>
      <Include value="trx" />
      <Include value="cov" />
    </Extensions>
  </Attachment>
  <LinkedBugs />
</DeletionCriteria>

I cannot see any size reduction in the database size. I have tried with over ride settings as well however nothing happens. 

I have searched Microsoft Forums but unfortunately there isn't enough help regarding this. Can anyone help ? how can i find out if test attachments are really deleted ? and if they are not being deleted, what can cause this ?

Regards
Faisal

How to find difference between 2 labels through TFS API

$
0
0

I have 2 labels. I want to know what is the difference between 2 labels.

Difference should contain how many files exist in only label1, how many files are different etc.

Can't get automated tests to run - get error adding test case [xx] could not load file or assembly 'Microsoft.VisualStudio.QualityTools.CodedUITestFramework

$
0
0

Here's our scenario. We are running TFS 2012 update 4. We have a Lab Mgmt system that runs on a server that has TFS 2012.4 build services, and SCVMM & HyperV software. The build runs on the server and spins up a snapshot of a VM. We run Automated CodedUI tests on the VM. The Build Server is also running as a Test Controller.

Our Automated Tests project is compiled using VS 2013.

When we run the Lab Management workflow, the VM is spun up, the files are copied to the VM's deployment folder, and then we get an error:

Error adding test case [54639] to test run: Could not load file or assembly 'Microsoft.VisualStudio.QualityTools.CodedUITestFramework, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.

That's the VS2013 dll. I've installed VS 2013 on the build/test controller Server and also on the VM. So those DLL's are there.

So how to fix? Where is it looking  for those DLLS (VM or Test Controller)?

Viewing all 6687 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>