Skip Headers
Oracle® WebCenter Framework Developer's Guide
10g (10.1.3.2.0)

Part Number B31074-05
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

11 Working Productively in Teams

This chapter contains advice for working on Oracle WebCenter Suite projects using Oracle JDeveloper and CVS, the integrated source control system. Before reading this chapter, you should read the chapter in Oracle Application Development Framework Developer's Guide regarding team development with CVS.

11.1 General Advice for Using CVS on WebCenter Applications

Working with CVS on a WebCenter application is similar to any other development environment with a source control system. However, it is quite different from the in-place editing paradigm used in Oracle Application Server Portal (OracleAS Portal). You should carefully review the Oracle JDeveloper online help system and Oracle Application Development Framework Developer's Guide for more information about CVS.

Getting Started

If you do not already have your application files source controlled in CVS, then you must import them into CVS before you can get started. To import the application files into CVS quickly, do the following:

  1. Open Oracle JDeveloper.

  2. Select View, CVS Navigator to bring up the CVS Navigator.

  3. Select your application in the Applications Navigator and under Versioning, select Import Module. If you already have a CVS connection, then you will be taken directly to the Import to CVS wizard. If you do not already have a CVS connection, then you will be prompted to create one as follows:

    1. If the Confirm Create Connection dialog box (Figure 11-1) appears, then click OK.

      Figure 11-1 Confirm Create Connection Dialog Box

      Description of Figure 11-1 follows
      Description of "Figure 11-1 Confirm Create Connection Dialog Box"

    2. If you are on the Welcome page of the wizard, then click Next to display the Connection page.

    3. On the Connection page (Figure 11-2), enter your connection information for CVS.

      Figure 11-2 Connection Page of Create CVS Connection Wizard

      Description of Figure 11-2 follows
      Description of "Figure 11-2 Connection Page of Create CVS Connection Wizard"

    4. Click Next.

    5. On the Root page (Figure 11-3), enter the Value of CVSROOT.

      Figure 11-3 Root Page of Create CVS Connection Wizard

      Description of Figure 11-3 follows
      Description of "Figure 11-3 Root Page of Create CVS Connection Wizard"

    6. Click Next.

    7. On the Test page (Figure 11-4), click Test Connection. The Log In to CVS dialog box is displayed, as shown in Figure 11-5.

      Figure 11-4 Test Page of Create CVS Connection Wizard

      Description of Figure 11-4 follows
      Description of "Figure 11-4 Test Page of Create CVS Connection Wizard"

      Figure 11-5 Log In to CVS Dialog Box

      Description of Figure 11-5 follows
      Description of "Figure 11-5 Log In to CVS Dialog Box"

    8. Enter your password and click OK.

    9. If the test is successful, then you should see something similar to Figure 11-6.

      Figure 11-6 Successful Test Page of Create CVS Connection Wizard

      Description of Figure 11-6 follows
      Description of "Figure 11-6 Successful Test Page of Create CVS Connection Wizard"

    10. Click Next.

    11. On the Name page, enter a value for Connection Name. The default name is the CVSROOT value, but you can change it to something more descriptive, as shown in Figure 11-7.

      Figure 11-7 Name Page of the Create CVS Connection Wizard

      Description of Figure 11-7 follows
      Description of "Figure 11-7 Name Page of the Create CVS Connection Wizard"

    12. Click Finish. The Import to CVS wizard is displayed.

  4. Click Next on the Welcome page of the wizard to display the Module page.

  5. On the Module page, choose Connection Name from the list.

  6. Enter a Module Name for the new module, as shown in Figure 11-8.

    Figure 11-8 Module Page of Import to CVS Wizard

    Description of Figure 11-8 follows
    Description of "Figure 11-8 Module Page of Import to CVS Wizard"

  7. Click Next.

  8. The Tags page specifies the tag names for the creation of the project. Leave the default values unchanged for the purposes of this example, as shown in Figure 11-9.

    Figure 11-9 Tags Page of Import to CVS Wizard

    Description of Figure 11-9 follows
    Description of "Figure 11-9 Tags Page of Import to CVS Wizard"

  9. Click Next.

  10. The Sources page specifies the location of the application. Leave the default value unchanged for the purposes of this example, as shown in Figure 11-10.

    Figure 11-10 Sources Page of the Import to CVS Wizard

    Description of Figure 11-10 follows
    Description of "Figure 11-10 Sources Page of the Import to CVS Wizard"

  11. Click Next.

  12. The Filters page specifies filters to exclude files from the import operation. Leave the default filters unchanged for the purposes of this example, as shown in Figure 11-11.

    Figure 11-11 Filters Page of Import to CVS Wizard

    Description of Figure 11-11 follows
    Description of "Figure 11-11 Filters Page of Import to CVS Wizard"

  13. Click Next.

  14. The Options page lets you specify whether you want to immediately check out the newly created module and begin versioning your project. Leave the default choice unchanged for the purposes of this example, as shown in Figure 11-12.

    Figure 11-12 Options Page of Import to CVS Wizard

    Description of Figure 11-12 follows
    Description of "Figure 11-12 Options Page of Import to CVS Wizard"

  15. Click Next. A summary of your chosen settings for this import operation is displayed for your review, as shown in Figure 11-13.

    Figure 11-13 Summary Page of Import to CVS Wizard

    Description of Figure 11-13 follows
    Description of "Figure 11-13 Summary Page of Import to CVS Wizard"

  16. Click Finish to execute the import operation. Other members of the team will now be able to check out the newly created module and commit changes.

11.2 Advice for WebCenter Application Files in CVS

One of the most important aspects of working with any source control system is understanding which files particular actions will touch. Without this knowledge, you may inadvertently corrupt the source by checking in or out either too few or too many files given the actions you are performing on the project. The tips in this section aim to help you understand what files are needed for the main actions you will perform in building a WebCenter application.

11.2.1 Files Associated With Common Objects

The main objects with which you work in a WebCenter application are as follows:

  • Pages

  • Portlets

  • Producers

  • Data controls

Each of these are fairly complex objects, made up of several different metadata files. For information about page metadata files, see Oracle Application Development Framework Developer's Guide. For information about portlet and producer metadata files, see Appendix C, "Files for WebCenter Applications".

11.2.2 Developer Actions Affecting Metadata Files

Table 11-1 lists the major developer actions and the files that are affected by these actions. You must take this information into account while managing your files in CVS.

Table 11-1 Files Affected by Developer Actions

Action Files Affected

Registering a producer

connections.xml is updated for a connection to the producer.

adf-config.xml is updated to configure the metadata repository and the external application configuration.

projectname.jws is updated to include the libraries needed for any WebCenter application.

applicationroot/mds/ adds a number of files pertaining to the registered producer.

WEB-INF/lib is the place to which portlet run time libraries are copied.

De-registering a producer

The producer is gone from the application, but you may need to manually remove the metadata files from CVS. Everything else should be left alone in case they have other producers which rely on the web.xml, adf-config.xml, connections.xml.

Placing a portlet on a page

pagename.jspx is updated to add the <adfp:portlet> tag. The .jspx is also transformed. JSF Faces tags are replaced with Oracle ADF faces tags.

pagenamePageDef.xml is updated with <portlet> tag.

WEB-INF/web.xml is updated to include the portlet servlets and filters.

applicationroot/mds/ adds a number of files pertaining to the newly cloned portlet instance.

faces-config.xml is added/updated whenever you add an Oracle ADF component (such as a portlet) to a page.

adf-faces-config.xml is added/updated whenever you add an Oracle ADF component to a page.

Removing a portlet from a page

Same files as placing a portlet on a page.


11.3 Implementing Common Requirements Once

It is good practice for the administrator of the project to implement any common developer requirements once and then checkin that version for all to use. By planning ahead and having the administrator take care of these common requirements up front, you can reduce redundancy and error.

For example, suppose two developers need to add Omniportlet on different pages of the application. If the project administrator has already registered the Omniportlet producer, then it is readily available for both of them to use. If not, then each developer will likely register the Omniportlet producer separately, leading to unnecessary duplication and confusion.

Another example would be the case of many developers needing content from the same Oracle Content Database repository. One person should setup and checkin the needed connection first. Other developers can then simply reuse the same data control

11.4 Producer Considerations

When working in a team environment, bear in mind the following considerations pertaining to producers:

11.4.1 Producer Connections

When building an EAR file for your project, connections are loaded for the entire application rather than individual projects. For example, suppose you have an application with two projects, P1 and P2. P1 has 100 registered producers and P2 has no producers. When you build an EAR file for either project, all 100 of P1's producer connections are loaded into connections.xml. Note, though, that you can also edit connections.xml manually.

When you run the Predeployment tool to create a targeted EAR file, all of the connections in connections.xml must be accessible. Hence, in our example, the generation of a targeted EAR file for either project would fail if any of the 100 producer connections for P1 are unavailable for some reason. Given this behavior, you must carefully consider how you plan to subdivide your overall development effort into applications and projects.

11.4.2 Producer Name Clashes

While Oracle WebCenter Framework enables you to register two producers under the same name, it is generally better to avoid this situation. For example, if two developers working on the same application inadvertently register a producer with the same name, then it is usually best to change one of the producer's names to be unique. If you have two producers registered under the same name, then it becomes very difficult to distinguish between them when debugging errors or performing administrative tasks on the producers.

11.4.3 Combining Portlets from Different Producers

In some cases, you might have multiple developers building portlets and ultimately you want those portlets to be combined under a single producer. To achieve this goal, your developers must be conscious of some potential issues.

  • Portlet names and JSP paths could clash. Portlet developers should use prearranged class package names and JSP paths to avoid naming clashes when portlets are combined within one producer in one application.

  • When you create a JPS portlet in the Portlet Wizard, the directory for the portlet modes defaults to portletn\html\mode_name, where n is a number that increments for each portlet you create. To avoid directory and file name clashes, portlet developers should change the directory name on the Content Type and Portlet Modes page of the Portlet Wizard. Select the portlet mode and then change the directory name in the corresponding field to something unique.

  • When you combine the portlets into one producer, you must manually merge the portlet descriptor files, avoiding identifier clashes as you do so as follows:

    • JPS portlet identifiers in the portlet.xml and oracle-portlet.xml files are automatically generated starting from portlet1. When you manually merge multiple portlet descriptor files into one, you must change any portlet identifiers that clash with one another.

    • Similarly, the PDK-Java portlet identifiers in provider.xml are automatically generated starting from 1. When you manually merge multiple provider.xml files, you must change any portlet identifiers that clash with one another.

  • You must also manually merge any Web descriptor (web.xml) changes, for example, security role information.

  • For PDK-Java portlets, you might also need to manually merge .properties files.

11.5 Security Considerations

Each time a developer updates the policy for a page or component (for example, an iterator or data control) using the Authorization Editor, the system-jazn-data.xml file in Oracle JDeveloper's embedded Oracle Containers for J2EE (OC4J) config directory (JDEV_HOME\system\oracle.j2ee.10.1.3.xx.xx\embedded-oc4j\config) is updated. At the same time, these changes are also propagated to the app-jazn-data.xml file, to enable the policies to be deployed with the application. As a result of this model, you should adhere to the following guidelines: