Sunday, December 23, 2012

APPLICATION LIFECYCLE MANAGEMENT


APPLICATION LIFECYCLE MANAGEMENT

Tools to achieve the following results:

1.       Plan & Track your project:
Enact processes and monitor their quality to help your team turn customer requirements into working software.

2.       Design:
Either on top of existing assets or from scratch by using architectural diagrams to communicate critical information about your team`s software.

3.       Write Unit Test, Debug, Analyze and Profile your Application:
Tools are integrated with the rest of the application lifecycle so that your team can understand how your progress contributes to the project.
Use Version Control to manage your source code & other files too.

4.       Build:
Build your Application using an integrated build system so that your team can ensure the quality gates have been meet and verify the requirements have been fulfilled in each build.

5.       Deploy into Virtual Environments:
To enable more sophisticated developing and testing.

VISUAL STUDIO APPLICATION LIFECYCLE MANAGEMENT


1.       Microsoft Test Manager:
Enables you to manage and execute test cases outside Visual Studio, and create and manage physical or virtual environments.

2.       VS Premium:
Toolset that simplifies the task of building Applications, Advanced coding, debugging, database, & testing tools to deliver scalable, high quality applications.

3.       VS Ultimate:
It Simplifies Solution development, lowering risk & increasing return of providing tools at every stage of lifecycle, from design & development through the test & development. You can design your application in UML, or analyse your existing software assets. You can define your Software Architecture & validate the design when your team checks in & builds with Team Foundation Server.


  
Application Lifecycle
Team Foundation Server
Microsoft Test Manager
Visual Studio Premium
Visual Studio Ultimate
Plan and Track
check mark
Design
check mark
Develop
check mark
check mark
check mark
Test
check mark
check mark
check mark
check mark
Build
check mark

Saturday, December 22, 2012

STEPS TO RESTORE FILE DELETE FROM TFS PROJECT


STEPS TO RESTORE FILE DELETE FROM TFS PROJECT

There may be times when you remove file by mistake and need to restore a most up to date copy of this file into the TFS Source Code repository. This task can be accomplished with the help of the TFS command line tools.

In order to recover file we need to run following line of code tf dir $//deleted command. This statement will give you a list of deletion IDs for all versions of the file. Once this command line has been ran, you will see the following output

projectFile1;X1
projectFile1.cs;X2
projectFile1.cs;X3

This list of files will give us good idea about the file that we want to recover. Once we determine versin of the file that we want to recover we run the following command line
tf undelete projectFile1.cs;X3

X3 is the version that we want to restore and as it was specified in our original, we are restoring most up to date file. This command will restore this file into the folder that this file was deleted from. It will copy this file into the current workspace that we are working in currently.

STEPS TO CREATE SHELVESETS


STEPS TO CREATE SHELVESETS

Shelving lets you set aside a batch of pending changes temporarily and optionally remove the pending changes from workspace. The product of the shelve operation is ashelveset. The changes in a shelveset can be restored later into your workspace or into another user's workspace.

When you check in one or more of the pending changes in your workspace, Team Foundation creates a changeset in the source control server. A changeset is a group of source file revisions, check-in notes, a comment, and links to associated work items. Similarly, a shelveset is a group of source file revisions, check-in notes, comments, and a list of associated work items. However, a shelveset does not contain a collection of committed and versioned file changes. Both shelvesets and changesets are stored on the Team Foundation server and can be retrieved into a workspace by any user who has sufficient permissions.

Other differences between changesets and shelvesets:
  1. ·         Unlike a changeset, a shelveset is a non-versioned entity. If you or another user unshelve the items of which a shelveset consists, edit several files, and reshelve the shelveset, Team Foundation does not create a new version of the items for future comparison and maintains no record of who revised the items, when, or in what manner. The original shelveset is completely replaced.
  2. ·         You can delete a shelveset but you cannot delete a changeset.
  3. ·         You can link a changeset to a work item so that when a user clicks the changeset link on the Links tab of the work item form, the changeset is automatically retrieved to the current workspace. This functionality is not supported for shelvesets.
  4. ·         You can prevent or at least, strongly discourage users from creating changeset that do not comply with established team standards by creating and enforcing check-in policies. This functionality is not supported for shelvesets. 

Shelve your pending changes when you are not ready to or cannot check in a set of pending changes. There are primarily five shelve scenarios:

·         Interrupt   When you have pending changes that are not ready for check in but you need to work on a different task, you can shelve your pending changes to set them aside.

·         Integration   When you have pending changes that are not ready for check in but you need to share them with another team member, you can shelve your pending changes and ask your team member to unshelve them.

·         Review   When you have pending changes that are ready for check-in and have to be code-reviewed, you can shelve your changes and inform the code reviewer of the shelveset.

·         Build   Before you check in your changes, you can use your build system to make sure that the changes in a shelveset will not break your regularly scheduled build processes, such as a nightly build. You can perform this validation manually by queuing a private build or automatically by implementing gated check-in.

·         Backup   When you have work in progress that you want to back up, but are not ready to check in, you can shelve your changes to have them preserved on the Team Foundation server.

·         Handoff   When you have work in progress that is to be completed by another team member, you can shelve your changes to make a handoff easier.

Shelvesets are created from either Source Control Explorer, the Pending Changes window, or the menu. For more information about how to create a shelveset see Shelve and Unshelve Pending Changes.

Unshelving Shelved Changes

Whereas you can restore a changeset into a workspace using the Get command, you must use the Unshelve Command to restore a shelveset. You can use the Unshelve button in the Pending Changes window to restore one, some, or all the pending changes in a shelveset to your workspace. When you unshelve all the changes in a shelveset to a workspace using Visual Studio, the pending changes information with which the items are associated is restored to the Pending Changes window also.
When you unshelve a shelveset, Team Foundation restores each shelved revision into the destination workspace as a pending change as long as the revision does not conflict with a change that was already pending in the workspace.

·         Edits   Team Foundation copies the contents of the source workspace version into the destination workspace version and checks out the file for edit.

·         Deletions   Shelved files and folders that were deleted pending check in to the source workspace are deleted in the destination workspace.

·         Additions   Shelved files and folders that were added to source control pending check in to the source workspace are added to the destination workspace.

·         Renames and Moves   Shelved files and folders that were renamed or moved in the source workspace are renamed and moved into their new folders in the destination workspace.

You can use the Unshelve command in Visual Studio or you can use the Difference Command from the command line to compare one, some, or all of the shelved file revisions in a shelveset to the base shelveset version, which is the server version of the item upon which it was based.

Unlike changesets, which are permanently stored in the source control server, you can delete shelvesets from the server.

USE TEAM FOUNDATION POWER TOOLS


USE TEAM FOUNDATION POWER TOOLS

Power Tools are a set of enhancements, tools and command-line utilities that increase productivity of Team Foundation Server scenarios.

1.      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.

2.      Team Foundation Server Backups
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.

3.      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.

4.      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.


5.      Team Explorer Enhancements 
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. You can also easily search for work items and be able to easily rollback changes in version control.

6.      Team Foundation Power Tool (TFPT.EXE) Tool
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.

7.      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.

8.      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.

9.      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.

STEPS TO CONNECT VB 6.0 PROJECTS TO TFS 2010


STEPS TO CONNECT VB 6.0 PROJECTS TO TFS 2010

Step 1: If local machine does not have installed VS 2010 then you need to install Visual Studio Team Explorer 2010. (http://www.microsoft.com/en-us/download/details.aspx?id=329) If doing on XP Machine you need to have SP3 Installed before doing this step.

Step 2: Once the installation is done local machine needs installation of Team Foundation Server MSSCCI Provider 2010. (http://visualstudiogallery.msdn.microsoft.com/bce06506-be38-47a1-9f29-d3937d3d88d6) This will replace the Existing VSS Menu in VB 6.0 IDE with Team Foundation.

Step 3: Now, you can see a Menu inside Tools > Team Foundation



Step 4: Now, you can add TFS Server, Create Project from Team Foundation, Add Project to Team Foundation, and check In, Check Out & get Latest Version.

STEPS TO CREATE PROJECT FOR BI/SSIS

STEPS TO CREATE PROJECT FOR BI/SSIS


Step 1: Open Visual Studio 2010.


Step 2: Go to View > Team Explorer


Step 3: Team Explorer > Connect to Team Project

Step 4:  Connect to Server


Step 5: Add TFS Server (if required)


Step 6: Select a Collection from Team Project Collections


Step 7: Click Connect


Step 8:  Team Explorer would be connected with the Collection you selected


Step 9: To Add Team Project into the Collection selected – Right Click on Collection in Team Explorer > Select New Team Project


Step 10: Enter Team Project Name & Description of Project (optional)


Step 11: Click Next > Select from the list Process Template to create Team Project

            Default selected is MSF for Agile Software Development v5.0

Step 12: Click Next > Select an Empty Source Control Folder option


Step 13: Click Next > Click Finish to create Project in TFS inside Project Collection selected


Step 14: Final Output in Team Explorer

                     
                 Team Explorer should be shown with the Project Name (in my case DemoProject) with Work Items, Reports (if configured on server), Builds & Source Control Section.

Step 15: Double Click on Source Control


            Following should be the Default Structure on Clicking on Source Control.

Step 16: Go to File > New > Project


Step 17: Select Template Database on left side > SQL Server > SQL Server 2008 Database Project


                At Bottom Right Select Add to Source Control > Ok (required to add code into source control TFS)

Step 18: Select Team Project into which you need to add the code



                Name a directory in which all the code will be created

Step 19: Below is the Output you need to obtain


Step 20: Right Click on Project Name > Check in Pending Changes

                This will commit changes on TFS Server > Note commands if required and say Check In


Step 21: below Steps are required only if Database is already created in SQL Server 2008 / SQL Server 2008 R2

Step 21.A: Go to Solution Explorer > Right Click on Project Name > Import Database Objects & Settings



Step 21.B: Select New Connection > Enter Details to connect to database


Step 21.C: Change the options to import (if required) > Start


Step 21.D: Import data > Finish


                This will import all the Table Scripts, Stored Procedures, Views, Triggers from the database connected.

Step 21.E: Following should be the structure shown of your database


Step 21.F: Right Click Project > Check In to commit changes on to TFS Server



Step 21.G: Right Click Project > Properties



Step 21.H: Select Deploy Section


Step 21.I: Change the Deploy Action to “Create a deployment script (.sql) and deploy to the database (required if database has to be deployed with the changes)


Step 21.J: Select Target Database Settings > Edit > Enter Details of Database > Ok


            Save the settings File

Step 21.K: Right Click Project > Check In




Step 21.L: Open the file in which you need to modify the scripts

Original Script: 



Modified Script:


Step 21.M: Commit your changes to TFS Server


Step 21.N: In-order to commit changes on to server database Right Click Project > Select Deploy


Step 21.O: Output Window will show all the changes committed to the database