Global Bank: Adding New Services to an Existing Web Site
In Visual Studio Team System 2008, you can model your application structure by using a top-down approach so that you don’t have to worry about the implementation details when you design. This article is the first in a series that will describe a common development scenario and show Visual Studio Team System 2008 in action. For background information, see Global Bank: A Scenario for Visual Studio Team System 2008.
Global Bank would like to expand the list of services they offer online to keep up with competitors. Recently, Alan, the company’s business analyst, surveyed customers for input about possible new online banking services. The feature that received the highest number of votes was the option to purchase United States Treasury Certificates of Deposit (CDs) online. After discussing the results of the survey with the Vice President of the division, Alan decides to request that the CD purchase feature be added to the Global Bank Web site.
Alan’s job includes working with the product team to define and implement new features for Global Bank. Even though the team uses Team System for project management, Alan is more comfortable with word processing and Internet browser software. As a result, Alan does not have Team System installed on his computer. Instead, he usually uses the Web client available in Team System 2008, called a project portal, to track the progress of projects.
To get the product team started, Alan drafts a list of requirements in Word and then schedules a meeting with Ken, the architect and program manager for the Global Bank Web site, to discuss his plans. Ken has been a developer for almost fifteen years, and has worked at Global Bank for the last seven years. He has been involved in the design and development of the Global Bank Web since its inception. Because of his dual role, Ken needs the functionality of both Visual Studio Team System Architecture and Team System Development. As a result, he has Visual Studio Team System 2008 Team Suite installed on his main computer.
Ken and Alan review the list of requirements for the new CD service and revise Alan’s initial requirements document until they are both satisfied. Because Alan does not have Visual Studio installed, Ken enters a task in the Global Bank Team Foundation Server work item database to design the new CD rate service. In the task description, Ken includes the requirements information on which he and Alan agreed. Ken then assigns the task to himself. He e-mails Alan a link to the read-only Web version of the task so that Alan can review the task description as well as track the progress of the item.
The next afternoon, Ken opens the system diagram for the Global Bank Web site in Team Suite. From the Toolbox, Ken adds a new system directly to the diagram. A new system diagram appears, which he names
CDService. The Global Bank Web site will connect to this new system to display CD rate information that is collected from the United States Treasury. Ken continues designing the new system by adding a blank ASP.NET Web application to CDService. He names this application
CDWebSite. This Web application will expose the CD information to the Global Bank Web site. Next, Ken adds two ASP.NET Web services and names them
CDRatesService, respectively. TreasuryBondService detects CD rates and CDRatesService allows customers to purchase CDs online. Ken then adds an External Database to the diagram and names it
GlobalBankDB. GlobalBankDB stores the CD rate information.
Ken now needs to define the flow of information between the items in CDService, which he does by adding endpoints. Each member needs to connect to CDWebSite, and CDWebSite connects to CDService. CDService then connects to the main Global Bank Web site. Ken quickly adds the appropriate endpoints from the Toolbox.
Figure 1: CDService Diagram
Ken is now ready to generate a code skeleton for the new system. Ken opens the application diagram and then selects CDWebSite on the design surface. He uses the Properties window to change the default implementation language to Visual C#. Ken then uses the Implement Application command to create a skeleton of the new Web application. Visual Studio stubs out a Visual C# Web application named CDWebSite, including basic files such as a web.config file and a default .aspx page with C# code behind. Ken renames default.aspx.cs to CDServices.cs and then opens the file to review the skeleton code automatically generated for him.
Ken makes some minor changes to the code and then saves his work. He makes a copy of the system diagram image and posts it under the Shared Documents folder in the Project Portal web site for the solution. He then e-mails the link to the diagram to Alan for his reference. Deciding he is finished, Ken then checks in all the changes he has made.
Before work can begin on coding the new service, Ken must enter work items for the database designer and the primary developer and tester for the new service. He then updates the status of the task assigned to him so that Alan can see the progress that has been made on the new service.