../E63259-01.epub /> ../E63259-01.mobi />

28 Integrating Documents

This chapter describes how to integrate documents into a Portal Framework application to both add content to the application, and to provide end users with content and documents task flows built into the application to manage, display, and search documents at runtime.


For a description of the other ways to integrate content into a WebCenter Portal Framework application, see Chapter 24, "Introduction to Integrating and Publishing Content."

This chapter includes the following topics:

28.1 Introduction to Documents in WebCenter Portal Framework Applications

The Documents tool provides features for accessing, adding, and managing folders and files; configuring and viewing file and folder properties; and searching file and folder content in Content Server, Oracle Portal, SharePoint, or, in development environments, File System content repositories. It provides these features through documents task flows, document components (links, inline frames, and images), wikis, and blogs.


The availability of SharePoint as a content repository requires the installation of the SharePoint adapter, as described in Section, "Installing the Oracle WebCenter Adapter for SharePoint." Administration for SharePoint is performed using WLST commands, not Oracle Enterprise Manager Fusion Middleware Control Console.

To integrate documents into a Portal Framework application, your WebCenter Portal administrator must set up a connection to the content repository that contains the documents you want to manage. If the content repository you wish to use requires authentication, ensure that you set up an external application when you configure the connection to your content repository, as discussed in Section 28.2, "Setting Up Connections."

28.2 Setting Up Connections

Before you can use the Documents tool and task flows, you must first set up the connection to the Content Server, Oracle Portal, or SharePoint content repository that contains the documents you want to manage. You can reuse connections you have created or create new ones.


While you can set up the connections to back-end servers at design time in Oracle JDeveloper, you can also later add, delete, or modify connections in your deployed environment using Enterprise Manager Fusion Middleware Control. For more information, refer to the Oracle Fusion Middleware Administering Oracle WebCenter Portal.

The choices made for application security and content repository connection authentication need to be compatible. For example, if the connection is configured to use External Application with only Public credentials defined, then there is no requirement for the application to enforce user authentication. For detailed information about connection configuration, see Section 25.2, "Configuring Content Repository Connections."

28.3 Setting Security for the Documents Tool

The documents task flows support the same security options that are supported by the content repository connections. This service can also use an external application with dedicated user accounts to access remote content repositories, such as an Oracle Content Server or Oracle Portal. For more information about using security with content repositories, see Section 26.4, "Securing a Content Repository Data Control." For information about using external applications, see Section 74.13, "Working with External Applications."

If you are using a content repository that handles its own authentication, such as Oracle Portal or Oracle Content Server, you can associate that content repository with an external application definition to allow for credential provisioning. You can modify your connection to your content repository to use an external application without shared or public credentials. When you do this, the External Application - Change Password task flow is automatically integrated to allow your end users to provide their credentials.

To register an external application for an existing content repository connection:

  1. In the Application Resources pane, right-click your connection name and choose Properties.

  2. In the Edit Content Repository Connection dialog box, under Authentication, select External Application (Figure 28-1).

    Figure 28-1 Selecting External Application in the Content Repository Connection Dialog

    Description of Figure 28-1 follows
    Description of "Figure 28-1 Selecting External Application in the Content Repository Connection Dialog"

  3. Click the green + (plus) sign to start the Register External Application wizard.

  4. On the Name page, enter an Application Name and Application Display Name, (Figure 28-2) then click Next.

    Figure 28-2 Naming the External Application

    Description of Figure 28-2 follows
    Description of "Figure 28-2 Naming the External Application"

  5. On the General page, under Authentication Details, choose BASIC from the Authentication Method list (Figure 28-3), then click Next.

    Figure 28-3 Choosing the BASIC Authentication Method

    Description of Figure 28-3 follows
    Description of "Figure 28-3 Choosing the BASIC Authentication Method"

  6. On the Additional Fields page, click Next.

  7. On the Shared Credentials page, click Next.

  8. On the Public Credentials page, select Specify Public Credentials, then enter the Username and Password for the content repository (Figure 28-4).

    Figure 28-4 Specifying the Public Credentials

    Description of Figure 28-4 follows
    Description of "Figure 28-4 Specifying the Public Credentials"

  9. Click Finish. Notice that your connection now uses the external application for authentication (Figure 28-5).

    Figure 28-5 Using the New External Application

    Description of Figure 28-5 follows
    Description of "Figure 28-5 Using the New External Application"

  10. In the Edit Content Repository Connection dialog box, click OK. In the Application Resources panel, notice that the external application now appears (Figure 28-6).

    Figure 28-6 External Application in the Application Resources Panel

    Description of Figure 28-6 follows
    Description of "Figure 28-6 External Application in the Application Resources Panel"

If you do not apply security and the content repository requires a login to access the content, the user will not be able to authenticate and thus will see only public content at runtime.

28.4 Using the Documents Tool with Other WebCenter Services

You can use the Documents tool with a variety of other WebCenter services. For example, you can add tags to documents in your content repository, search across your application and retrieve documents in the results, or track recent changes to the content repository.

You can see an example of how to use the Documents tool with the Tags service in Section 44.3.3, "Optional Way to Show Tags on Pages."

To learn more about how you can use these services together, refer to Chapter 4, "Preparing Your Application for WebCenter Portal Tools and Services,"


When you integrate the Documents tool with the Search service, the Search service returns results from all content repository connections.

28.5 Setting Parameters to Upload Files to Content Repositories

The Document Manager, Document Explorer, and Folder Viewer task flows allow you to upload files into content repositories. WebCenter Portal Framework uses Apache MyFaces Trinidad to handle file upload from a browser to the application server.

To change the default settings of Apache MyFaces Trinidad, you can add three parameters to the web.xml file. To edit this file, open the ViewController project of your application. Under Web Content, open the web.xml file. In the Overview, navigate to Application > Context Initialization Parameters, then click the green plus sign (+) to add the parameters and their values (as described in Table 28-1) or simply update the code in the Source view. After you have made your changes, save the web.xml file, then restart Oracle JDeveloper.

Table 28-1 Apache MyFaces Trinidad Parameters

Parameter Description

The maximum amount of memory in bytes that a single file can use when uploaded


The maximum amount of disk space in bytes that a single file can use when uploaded


The directory in which the file being uploaded is temporarily stored

For more information, see the Apache MyFaces Trinidad documentation at http://myfaces.apache.org/trinidad/devguide/fileUpload.html.