Thursday, September 29, 2011

Windows Azure Tools 1.4 - Error: Certificate: ‘CertName’ with Thumbprint: xxx for Role: RoleName has not been uploaded to the hosted service: ServiceName.

Consider your Windows Azure role has a configuation like:

<Certificates>
  <Certificate name="CertName" thumbprint="xxx" thumbprintAlgorithm="sha1" />
</Certificates>

When you try to deploy to cloud from Visual Studio by right clicking the Windows Azure project and selecting Publish, you might see a log like this:
5:20:37 PM - Preparing...
5:20:37 PM - Connecting...
5:20:38 PM - Error: Certificate: ‘CertName’ with Thumbprint: xxx for Role: RoleName has not been uploaded to the hosted service: ServiceName.


The reason for this error could be that the Certificate Thumbprint which is displayed on the Windows Azure Portal is in UpperCase and the one specified in your configuration is in LowerCase or vice versa.

The fix for this is to copy the Thumbprint from Windows Azure Portal  and paste it in your configuration so that the case match at both places.

Friday, September 23, 2011

TFS 2010 - There was no endpoint listening at http://buildagent:9191/Build/v3.0/Services/Controller/1 that could accept the message

Sometimes the build agent stops working all of a sudden and you see the error:
There was no endpoint listening at http://buildagent:9191/Build/v3.0/Services/Controller/1 that could accept the message

This could occur because of incorrect proxy being set. If you uncheck the below checkbox or correct the proxy, it should fix the issue.

















The other fix for this is to unregister the Build Services and Register it again. Below are the steps:
  • Open Team Foundation Administration console
  • Go to Build Configuration
  • Click "Unregister" link on the build service
  • Click "Register" link on the build service
  • Specify the "Team Project Collection" and "Credentials" and Save

Monday, September 12, 2011

TFS 2010 Lab Management - There are no test cases matching the criteria specified

Have you seen the below error while running the Build-Deploy-Test worklow using Lab Managemnt in TFS 2010. "There are no test cases matching the criteria specified. Use Microsoft Test Manager to view the test cases."

Following are the possible causes for this error:
  • You are not building the test projects in the Build. Hence the test binaries are missing in TestDirectory.
  • You have not selected the correct Test Plan or Test Suite in the Test section of the Lab Build Definition which has the automated test cases .
  • The Test Confirugation selected in the Test section of the Lab Build Definition does not match the Configuration selected for the automated test case in Microsoft Test Manager.

Monday, August 29, 2011

VS 2010 Load Test - The ConnectionString property has not been initialized

Have you seen the below error while running a load test in VS 2010
---------------------------
Microsoft Visual Studio
---------------------------
Could not read result repository: The ConnectionString property has not been initialized..


Will display the runtime result instead of the repository result.
---------------------------
OK
---------------------------

 The reason is that you have selected "None" in the "Storage Type" property of the Run Settings. Instead select "Database" and you should not see this error.

Tuesday, August 23, 2011

TFS 2010 - The process cannot access the file 'data.coverage' because it is being used by another process

Have you came across a situation where your build is running indefinitely and when you see stop the build, the following error is thrown:

The process cannot access the file 'data.coverage' because it is being used by another process.

This happens only when code coverage is enabled in the testsettings being used in the build. Also, you will see this issue if one of your unit tests is having an issue. To know about the root cause of the issue with the unit test, you can do the following:
  • Go to the build agent box
  • Browse to the directory where the build agent "Sources", "Binaries" and "Test Results" folder are present
  • Open the trx file in the "Test Results" folder
  • Click on "Test run error"
You will see the exact cause of the issue here.

Also, if you dont want to Stop the build forcefully and allow it to finish the execution, please follow these steps:
  • Go to the build agent box
  • Go to Task Manager and kill the process "VSPerfMon.exe"
This will allow the build to complete gracefully but you will not see any unit test and code coverage results.