WebSphere Studio Application Developer Version 5 Programming Guide part 79 pps

10 83 0
WebSphere Studio Application Developer Version 5 Programming Guide part 79 pps

Đang tải... (xem toàn văn)

Thông tin tài liệu

754 WebSphere Studio Application Developer Version 5 Programming Guide Figure 23-3 ClearCase preferences dialog If you click Advanced Options and then select the Operations tab, you can select if you want ClearCase to generate backup copies of files you perform an undo check out operation on. The backup copies will have a .keep extension. The ClearCase online help in Application Developer contains a detailed description about each option of the preferences page. Using ClearCase with Application Developer This section describes a scenario with two developers, developer 1 and 2, working on a Web project called ITSOProGuideCCWeb. Developer 1 is assigned the role of project integrator and is responsible for setting up the environment. Note: You must be connected to ClearCase for the Advanced Options button to be active. Chapter 23. Using ClearCase 755 Developer 1:  Creates a new VOB, ITSO_VOB  Creates a new ClearCase project, ITSO_Project  Joins the ClearCase project by creating views  Creates a new Web project, ITSOProGuideCCWeb  Moves the project under ClearCase source control  Adds a servlet, ServletA  Checks in the servlet  Delivers the work to the integration stream  Makes a baseline Developer 2:  Joins the ClearCase project by creating views  Imports the project into Application Developer  Adds a servlet, ServletB  Checks in the servlet  Verifies that no other developers has modified the project by performing a Rebase preview operation  Delivers the work to the integration stream  Makes a baseline Developer 1:  Updates his view to get the latest changes The setup of this scenario and its flow is shown in Figure 23-4. ClearCase terminology is used for the tasks. Figure 23-4 Scenario setup Developer 2 Developer 1 Make Baseline dev1_View Rebase Stream Deliver Stream Make Baseline Rebase Stream Deliver Stream dev2_View ITSO_VOB ITSO_Project ITSO_ Project_ Integration Baselines dev2_IntegrationView dev1_IntegrationView ___________________Workstation 1_______________ _____Workstation 2_____ Update View Update View 756 WebSphere Studio Application Developer Version 5 Programming Guide Note that the integration view is like a window to the integration stream. The integration stream should be reserved for only that code that has passed the developer’s inspection and is sharable to the entire team. Basically, the developer retrieves the latest version of the code from the VOB to the integration view by using the ClearCase Update View function. Once this is done the developer can use the Rebase Stream function to update the development view and start working with the code. When finished with the changes, the developer delivers the development stream back to the integration stream. A project integrator (or any of the developers) can then make a new baseline freezing the latest code changes. Setting up ClearCase for a new project Developer 1 (user ID dev1) works on the machine where the ClearCase LT Server is installed and developer 2 (dev2) works on the machine where only the ClearCase LT Client is installed. Creating a new VOB As developer 1, select Start -> Programs -> Rational ClearCase LT Server -> Create VOB . This brings up the VOB Creation Wizard (Figure 23-5). Enter ITSO_VOB as the VOB name. Then click Finish . Figure 23-5 Creating new VOB On the confirmation page, click OK . ClearCase now creates a new VOB. Click Close on the summary dialog. Chapter 23. Using ClearCase 757 Creating new ClearCase project Developer 1 create a new project under ClearCase control:  As developer 1, select Start -> Programs -> Rational ClearCase LT Server -> Rational ClearCase LT Project Explorer .  Select File -> New -> Project . This opens the New Project Wizard (Figure 23-6). Enter ITSO_Project as the project name and click Next . Figure 23-6 Creating new project: step 1  In the Step 2 dialog (Figure 23-7) make sure that No is selected. Click Next . Figure 23-7 Creating new project: step 2 758 WebSphere Studio Application Developer Version 5 Programming Guide  In the Step 3 dialog (Figure 23-8) click Add : – In the Add Baseline dialog, select the component ITSO_VOB from the drop-down list and select ITSO_VOB_INITIAL under Baselines. – Click OK.  Click Next. Figure 23-8 Creating new project: step 3  In the Step 4 dialog (Figure 23-9) select ITSO_VOB under Make the following components modifiable. Leave the other values as their defaults. Click Next . Chapter 23. Using ClearCase 759 Figure 23-9 Creating new project: step 4  In the Step 5 dialog, select No and click Finish .  Click OK on the confirmation dialog. ClearCase now creates the project and it shows up in the Project Explorer. Joining a ClearCase project The next step for developer 1 is to join the project and create a new Web project in Application Developer.  As developer 1, start Application Developer and select ClearCase -> Connect to Rational ClearCase (unless you specified to automatically connect to ClearCase when Application Developer starts).  Select ClearCase Create -> New View .  In the View Creation Wizard (Figure 23-10), select Ye s to indicate we are working on a ClearCase project. Expand projects and select the ITSO_Project . Click Next . 760 WebSphere Studio Application Developer Version 5 Programming Guide Figure 23-10 Creating a new view  In the Create a Development Stream dialog (Figure 23-11) enter dev1_View as the development stream name and make sure the integration stream name is ITSO_Project_Integration . Click Next . Figure 23-11 Creating a development stream Chapter 23. Using ClearCase 761  In the Choose Location for a Snapshot View (Development View) dialog (Figure 23-12) change the location to C:\ITSO\dev1_View. Click Next and click Ye s on the confirmation dialog. Figure 23-12 Specifying location for development view  In the Choose Location for a Snapshot View (Integration View) dialog (Figure 23-13) change the location to C:\ITSO\dev1_IntegrationView. Click Next. Figure 23-13 Specifying location for integration view 762 WebSphere Studio Application Developer Version 5 Programming Guide  In the Choose Components dialog, leave the ITSO_VOB selected and make sure Start component browser after creating view is deselected. Click Finish .  In the Confirmation dialog (Figure 23-14) click OK. Figure 23-14 View creation confirmation dialog  In the View Creation Status dialog that is displayed after the views are created, click OK . Creating a Web project Developer 1 has now created necessary views and joined the project. The next task is to create a Web project and add it to ClearCase control  As developer 1, open the Web perspective and select File -> New -> Web Project . In the Create a Web Project dialog, enter ITSOProGuideCCWeb as project name and make sure the Use Default location is selected (this is a directory under the Application Developer workspace and is different from the ClearCase view locations). Click Next .  On the J2EE Settings page, select New and enter ITSOProGuideCCEAR as the name for the Enterprise application project. Click Finish . Adding a project to ClearCase source control To add the new project under ClearCase control:  As developer 1, select the ITSOProGuideCCEAR project in the J2EE Navigator view and select Team -> Share Project from the context menu.  In the Share Project dialog, select Rational ClearCase and click Next . Chapter 23. Using ClearCase 763  In the Move Project Into a ClearCase VOB dialog (Figure 23-15) click Browse and select C:\ITSO\dev1_View\ITSO_VOB. Click OK and then Finish . Figure 23-15 Moving project into ClearCase  In the Add Elements to Source Control (Figure 23-16) leave all items selected and deselect Keep checked out . Click OK. Figure 23-16 Specifying elements to add to source control  In the Select Activity dialog (Figure 23-17) select New and enter Developer 1 adds project to source control. Click OK to return and then click OK to continue. The EAR project is now added to ClearCase source control. . 754 WebSphere Studio Application Developer Version 5 Programming Guide Figure 23-3 ClearCase preferences dialog If you click Advanced. 1_______________ _____Workstation 2_____ Update View Update View 756 WebSphere Studio Application Developer Version 5 Programming Guide Note that the integration view is like a window to the integration. selected. Click Next . Figure 23-7 Creating new project: step 2 758 WebSphere Studio Application Developer Version 5 Programming Guide  In the Step 3 dialog (Figure 23-8) click Add : – In the

Ngày đăng: 03/07/2014, 20:20

Từ khóa liên quan

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan