B Replicating Your Site

The web sites that you create with Oracle Site Studio reside on a single instance of the content server. At some point, you may want to copy the site from one content server to another. This process is called replication, and it is often used by administrators to reproduce a site on two (or more) content servers. For example, a development server and a production server. The copying process can be automated so that your site remains current on all servers.

This section covers the following topics:

B.1 About Replication

To better understand replication, you should be aware of the terminology and processes that are involved. Because Oracle Site Studio relies on the content server's Archiver/Replicator tool to replicate the site, you can refer to the content server documentation for more information.

To replicate your site, you must perform several steps to ensure that the site works properly on the server you're copying it to (the target server). You must prepare that server environment, configure the two servers so that they communicate with one another, set up archives on both servers, and perform the replication.

You find most of the replication features on the Manage Site Replication page in the content server, but you can also use Oracle Site Studio Replicator to customize the replication even more. You can use this four-part wizard to replicate individual sections of the site, merge sections on the target server, and override environment properties.

When you replicate a site, you copy the site hierarchy, site assets, and more. The replication feature in Oracle Site Studio uses the existing replication framework in the content server (Archiver/Replicator). As such, if you've worked with that tool before, many of the steps in Oracle Site Studio will already be familiar to you.

Replication is described in more detail in these sections:

B.1.1 The Replication Process

The replication process in Oracle Site Studio includes a source server, a target server, an export archive, an import archive, and the transfer.

Figure B-1The Stages Involved in Replication

Description of Figure B-1 follows
Description of "Figure B-1The Stages Involved in Replication"

  • Export: Native files, web-viewable files, content types, and user attributes are copied out of the source content server into an export archive.

  • Import: Files and content server information are copied from an import archive to the target content server.

  • Transfer: Content is transferred from one content server to another. This function can be used to copy content across a firewall or between two servers that do not have access to the same file system. You can also transfer archives between two content servers that have access to the same file system.

  • Replicate: Automates the export, import, and transfer steps. You can use replication to automatically export from one content server, transfer the archive to another computer, and then import to another content server.

The replication process consists of several steps:

  1. Section B.2, "Configuring the Target Server for Replication"

  2. Section B.3, "Setting Up an Outgoing Provider on the Source Server"

  3. Section B.4, "Creating the Import and Export Archives"

  4. Section B.5, "Starting the Site Replication"

  5. Section B.6, "Specifying Environment Properties"

B.1.2 What Gets Replicated

When you use the Oracle Site Studio Replication feature to replicate your site from one content server to another, the following items are included:

  • Project file (the dDocName of the project file)

  • Web site ID (where the xWebsites field contains the SiteID of the site)

  • Web site sections (where the xWebsiteSection field contains the SiteID of the site)

  • Fragment libraries (where the xWebsiteObjectType field contains the value "fragment")

It is important that the metadata values for xWebsites, xWebsiteSection, and xWebsiteObjectType be used correctly on your site in order for the contents of the site to be replicated.

B.1.3 Revisions Included

Revisions with a release date later than the most recent export date are exported. This prevents archives from exporting material that has already been exported, which ensures the migration of content only one time and prevents the unfettered growth in the size of the archives. Furthermore, all selected revisions of content that match the export query are exported to the archive. This works in tandem with the release date filter to ensure that the required web site content is replicated.

B.1.4 Additional Export Settings

The Oracle Site Studio Replication feature includes several other useful settings to ensure that your site is successfully replicated:

  • Configuration information for the content is included for administrators who plan to synchronize metadata models between two content servers. (Oracle Site Studio does not use this information.)

  • The source archive is identified as the transfer owner (the content server that initiates the transfer from the source archive to the target archive).

  • The import archive on the target server is identified as the target archive, which takes responsibility for receiving material exported and transferred from a source server and then imports the material into the target server.

B.2 Configuring the Target Server for Replication

The Oracle Site Studio replication feature copies your site from one content server to another. It it does not, however, copy the content server environment from the source server to the target server.

Before you replicate the site, you must make sure the content server environment on the target server is set up the same way as the source server (at least the parts used by your site). If you skip this step, your web site experiences problems during the replication process.

The steps to reproduce the content server environment varies from one organization to another and from one web site to another. As such, we offer these general guidelines.

To manually configure the target server environment, perform these tasks:

  1. Recreate the metadata model used on the source server. This includes all custom metadata fields and new file formats. This metadata is required for your site to operate properly. For example, checking in files generally relies on your metadata settings, and certain features on your site rely on custom metadata fields.

  2. Reinstall all components used by your site on the source server. This includes Dynamic Converter (for native documents) and Check Out and Open (to check native documents out using the contribution icon).

  3. Recreate unmanaged resources. This includes custom ActiveX controls or JSP objects that are used by your site.

  4. Recreate any additional configuration settings that you have introduced to the server. This includes anything that has changed the behavior of the server.

If you run version 7.5.2 or later of Oracle Content Server (including 10gR3), then you may be able to use the Content Server Configuration Migration Utility to replicate the content server environment. The next step is to set up an outgoing provider (see Section B.3, "Setting Up an Outgoing Provider on the Source Server").

B.3 Setting Up an Outgoing Provider on the Source Server

In Oracle Content Server, a provider is an API (Application Programming Interface) that establishes a connection between two or more content servers. To replicate a web site, you must create an outgoing provider on the source server that establishes a connection between it and the target server.

After you configure the target server (see Section B.2, "Configuring the Target Server for Replication"), you are ready to set up an outgoing provider on the source server.

To set up an outgoing provider on the source server, perform these tasks:

  1. Log on to the source content server as an administrator. On the main menu, select Administration and then Providers.

    Figure B-2Provider Page in Oracle Content Server User Interface

    Provider Page in Content Server user interface
  2. Under Create a New Provider, click Add beside the outgoing provider type.

    This opens the Add Outgoing Provider page.

    Figure B-3Add Outgoing Provider Page

    Add Outgoing Provider
  3. For Provider Name, enter a name to identify the provider (see illustration above). The name appears in the Providers list on this page (after you add one), and it becomes a subdirectory in the [CS-Dir]/data/providers/ on the source server.

  4. For Provider Description, enter a friendly description for the provider (see illustration above).

  5. For Provider Class, enter intradoc.provider.SocketOutgoingProvider (the name of the Java class for outgoing providers).

  6. For Connection Class, enter intradoc.provider.SocketOutgoingConnection (the name of the Java class that implements provider connections).

  7. You can leave Configuration Class empty (this identifies a Java class for additional configuration settings, useful for database providers).

  8. For Server Host Name, enter the name (typically, the system name or IP address) of the target server.

    A socket connection is made to this host.

  9. You can leave HTTP Server Address empty (this is the HTTP address of the target server, which is not necessary for this type of connection).

  10. For Server Port, enter the port (typically, 4444) used to communicate with the target server.

    You can determine the port by viewing the server output when starting the content server.

  11. For Instance Name, enter the name (IDC_Name) of the target content server.

  12. For Relative Web Root, enter the relative web root for the target content server (for example, /stellent/).

    You can skip the remaining options as they are not required for this type of connection.

  13. Press Add to save the provider information and return to the Providers page. (Your outgoing provider is in the Providers list.)

  14. Restart the content server.

To test the provider and make sure it was properly set up, return to the Providers page and click Test beside the outgoing provider.

In addition to setting up the outgoing provider, you may still must configure the server IP address filter on the target system so that the source server is allowed to communicate with the target server (for more information, see the Oracle Content Server Help).

If there is a firewall in place, you must allow connections from the source server to the target server on the port defined in step 10.

The next step is to create an import archive (see Section B.4.1, "Setting Up the Import Archive on the Target Server").

B.4 Creating the Import and Export Archives

When you replicate your site from one content server to another, the Oracle Site Studio replication feature exports the contents of your site into an export archive. The export archive content is copied into an import archive, residing on the target server. The import archive is then extracted to that server so that your site can be viewed and used again on the new server.

You create the export archive on the source server and an import archive on the target server. You must create the import archive on the target server first, however, so that you can point the export archive to that location when you set one up.

B.4.1 Setting Up the Import Archive on the Target Server

An import archive resides on the target content server. During replication, content from an export archive (residing on a source server) is copied into the import archive. The import archive then copies the content to the target content server, thus completing the replication process.

After you set up a provider connection (see Section B.3, "Setting Up an Outgoing Provider on the Source Server"), you're ready to create an import archive. You create (or edit) an import archive on the Manage Site Replication page on the target server.

To set up an import archive, perform these tasks:

  1. Log on to the target content server as an administrator. On the main menu, select Administration, then Oracle Site Studio Administration, and then Manage Site Replication.

    This opens the Manager Site Replication page.

  2. Click Add Import Archive.

    This opens the Add Import Archive page.

    Or, if you are updating an existing import archive, highlight it in the list of archives and click Change Settings.

  3. Enter a name for the archive beside Archive Name (the name appears in the list of available archives on the Manage Site Replication page).

    The archive name should not contain spaces or special characters.

  4. Enter a description of the archive beside Archive Description.

  5. To retain content that contributors assign to each region on the target site, check Retain switched region content on target server during import.

    These are the areas where a contributor has switched the data file or native document.

  6. To retain content that contributors edit in each region on the target site, check Retain region content on target server during import.

    This prevents any data files and native documents from being copied from the source server to the target server and potentially overwriting files edited by the contributor.

  7. Click Add Archive.

    Or, if you are updating an existing import archive, click Update.

    You would typically choose to retain region content and switched region content if you're replicating from a development server (source) to a contribution server (target) because in that scenario you want to preserve the changes made by a contributor.

You would likely disable (uncheck) these options if you're replicating from a contribution server (source) to a consumption server (target) because in that scenario you want to overwrite anything that has changed on the consumption server.

The next step is to create an export archive (see Section B.4.2, "Setting Up the Export Archive on the Source Server").

B.4.2 Setting Up the Export Archive on the Source Server

An export archive resides on the source content server, where it collects information from the web site. During replication, the export archive is copied to an import archive, residing on the target server. (That import archive must be created first so that you can point to it when you create the export archive.)

After you create an import archive (see Section B.4.1, "Setting Up the Import Archive on the Target Server"), you're ready to create an export archive. You create (or edit) an export archive using the Manage Site Replication page on the source server.

To set up an export archive, perform these tasks:

  1. Log on to the source content server as an administrator. On the main menu, select Administration, then Oracle Site Studio Administration, and then Manage Site Replication.

    This opens the Manage Site Replication page.

  2. Click Add Export Archive.

    This opens the Add Export Archive page.

    Or, if you are updating an existing export archive, highlight it in the list of archives and click Change Settings.

  3. Enter a name for the archive beside Archive Name (the name appears in the list of available archives on the Manage Site Replication page).

    The archive name should not contain spaces or special characters.

  4. Enter a description of the archive beside Archive Description.

  5. Choose the web site to replicate in the Web Site menu.

  6. Check Include project file in export archive to replicate your entire site hierarchy.

    If you do not want to replicate the entire site hierarchy and instead want to replicate individual sections, then leave this option unchecked, continue with the steps below and then follow the steps in Section B.7, "Replication Individual Sections of Your Site."

  7. For Transfer to Collection, select the collection on the target content server where this archive is copied to.

    Click Open Collection to browse to the collection on the target server.

  8. For Transfer to Archive, select the archive on the target server where this export archive is copied to (see Section B.4.1, "Setting Up the Import Archive on the Target Server").

  9. Check Automatically export new and changed content if you want the replication process to be automatic whenever content on the source server changes. (If you do not choose this, then you must manually trigger the replication.)

  10. Click Add Archive.

    Or, if you are updating an existing export archive, click Update.

When you select a web site for the export archive (Step 7), Oracle Site Studio archives and replicates everything related to your site (see Section B.1.2, "What Gets Replicated"). To customize what gets archived or to add more items to the archive, you can refine the archive query directly using the Archiver applet.

The next step is to start the replication (see Section B.5, "Starting the Site Replication").

If you plan to use Oracle Site Studio Replicator to replicate individual sections of your site, then the next step is opening the Oracle Site Studio Replicator (see Section B.8, "Using Oracle Site Studio Replicator").

B.5 Starting the Site Replication

After you've set up an export archive (see Section B.4.2, "Setting Up the Export Archive on the Source Server"), you're ready to initiate the replication process on the source server using the Manage Site Replication page.

To replicate your web site, perform these tasks:

  1. Log on to the source content server as an administrator. On the main menu, select Administration, then Oracle Site Studio Administration, and then Manage Site Replication.

    This opens the Manage Site Replication page.

  2. Select the desired export archive.

  3. Click Export.

If you chose to automatically export new and changed content (Step 10 in Section B.4.2, "Setting Up the Export Archive on the Source Server"), then the replication process is automatic after you export the archive.

Note:

The first time you export a web site, it must be done manually. If the site is set for automatic export, de-select the Automatically export new and changed content checkbox, then click Export to run the first export manually. After this first manual export, replication can be made automatic.

Depending on the size and complexity of your site, you may must allow plenty of time for the target content server to re-index your site when the replication is complete.

B.6 Specifying Environment Properties

When replicating your site from one location to another, you may want to preserve certain settings from one server and not replicate them to the next server. These settings are called environment properties.

If, for example, you want to specify a unique caching value on one server (a contribution site) and not the next server (a customer site), you would specify that the max-age property be an environment property. As a result, it is not replicated to the next server.

You specify environment properties in Designer, and you can override those values in Replicator.

To specify environment properties, perform these tasks:

  1. With your site open in Designer, click File then Site, then select Advanced then Define Environment Properties.

    This opens the Define Environment Properties dialog (see Section A.7, "Define Environment Properties Dialog").

  2. Check the box beside the property to be an environment property (and therefore not replicated).

  3. Clear the box beside the property to be treated normally and therefore replicated to the next location (these properties are called application properties).

  4. Click OK.

You can also override environment properties during replication (see Section B.8.6, "Overriding Environment Properties").

B.7 Replication Individual Sections of Your Site

Instead of replicating an entire web site in one action, you may want to replicate individual sections of the site. This is useful, for example, if you have a section that is not ready for public viewing, so you hold off on replicating that section until it is ready.

Or perhaps, you have a section that is only intended for a production environment and not a consumption environment. As such, you would want to omit that section when replicating the site hierarchy.

You use Oracle Site Studio Replicator to replicate individual sections of your site. For more information, see Section B.8, "Using Oracle Site Studio Replicator."

Before you proceed, you should verify that you have unchecked the project file in your export archive (Step 7 in Section B.4.2, "Setting Up the Export Archive on the Source Server"). If not, your replication settings in Oracle Site Studio Replicator are overwritten by the replication of the entire site hierarchy.

B.8 Using Oracle Site Studio Replicator

Oracle Site Studio Replicator is a tool that you use with Oracle Site Studio to replicate portions of your site hierarchy from one content server (the source server) to another (the target server). Without Oracle Site Studio Replicator, you must replicate the entire site hierarchy. Oracle Site Studio Replicator can also be used to override environment properties on your site.

Oracle Site Studio Replicator only replicates your site hierarchy; it does not replicate the content on your site (page templates, data files, fragments, and so on). This content is replicated when you use the Manage Site Replication page.

Starting Oracle Site Studio Replicator

Oracle Site Studio Replicator is installed locally on your system with Designer when you install Oracle Site Studio. You can launch this program from your Start menu: select Programs, then select Oracle Universal Content Management, then select Oracle Site Studio 11gR1, and choose Oracle Site Studio Replicator.

With the program open, you are ready to go through the wizard and replicate your site hierarchy. The replication process consists of several steps:

B.8.1 Step 1: Selecting a Source Server and Web Site

The first screen in Oracle Site Studio Replicator asks you to select a source server. This is the server where you are replicating your site hierarchy from. You can select a source server by selecting the actual server or a project file created on the source server. Once you select a server, you then select a web site. For more information, see Section A.82.1, "Step 1: Select Source Server."

Selecting a Server as the Source

To select a server as the source, perform these tasks:

  1. Select a server from the Source Content Server drop-down list.

    Figure B-4Selecting a Server

    Server Selection

    To add a server, edit an existing one, or remove one, click the Additional Information icon (Figure B-5) beside the drop-down list (see Section B.8.5, "Modifying Server Connections").

    Figure B-5Additional Information Icon

    Additional Information Icon
  2. Click Next (and when prompted, log onto the content server).

  3. Select a web site on the source server.

    Figure B-6Selecting a Web Site

    Selecting a Web Site
  4. Click Next and proceed to the next step (see Section B.8.2, "Step 2: Selecting a Target Server").

Selecting a Project File as the Source

You can use a project file as the source, but you must first download the project file from the source server (see Section 7.3.4, "Viewing the Content Information Page for the Project File"). Using a project file instead of a source server is useful when you must manually transfer the hierarchy because the source server is not accessible on the network.

To select a project file as the source, perform these tasks:

  1. Select <Load From File> from the Source Content Server drop-down list.

  2. Click Next.

  3. From the Open dialog, select the project file that you downloaded from the source server and click OK.

  4. Click Next and proceed to the next step (see Section B.8.2, "Step 2: Selecting a Target Server").

Later in the wizard, you have the opportunity to select individual sections from the web site you are replicating.

B.8.2 Step 2: Selecting a Target Server

The next screen in Oracle Site Studio Replicator asks you to select a target server. This is the server where you are replicating your site hierarchy to. You can select the server by selecting the actual server or a project file on the target server. For more information, see Section A.82.2, "Step 2: Select Target Server."

Selecting a Server as the Target

To select a server as the target, perform these tasks:

  1. Select a server from the Target Content Server drop-down list. (It is not valid to leave the Target Content Server field blank.)

    Figure B-7Selecting a Server

    Server Selection

    To add a server, edit an existing one, or remove one, click the Additional Information icon (Figure B-8) beside the list of servers (see Section B.8.5, "Modifying Server Connections").

    Figure B-8Additional Information icon

    Additional Information Icon
  2. Click Advanced and choose an option:

    • Choose Replicate hierarchy information directly to the target content server to replicate to the target content server directly.

      This option is only available when you choose a server as the target (as opposed to a project file).

    • Choose Generate a hierarchy information file for manual replication to generate a hierarchy information file.

      Specify an Output File Name for the hierarchy information file or click Browse to locate one.

      By choosing this option, a project file is created that you can later check into the content server.

  3. Click OK to return to Oracle Site Studio Replicator.

  4. Click Next (and log onto the content server, if prompted).

  5. If prompted to create a web site (the project file), click Yes.

  6. Proceed to the next step (see Section B.8.3, "Step 3: Selecting Items to Replicate").

Selecting a Project File as the Target

You can use a project file as the target, but you must first download the project file from the target server (see Section 7.3.4, "Viewing the Content Information Page for the Project File"). Using a project file instead of a target server is useful when you must manually transfer the hierarchy because the target server is not accessible on the network.

To select a project file as the target, perform these tasks:

  1. Select <Load From File> from the Target Content Server drop-down list.

  2. Click Next.

  3. Click OK when prompted that an output file name is required.

  4. In the Output File Name field, specify a name for the hierarchy information file.

    Or, click Browse to locate an existing file.

  5. Click OK to return to Oracle Site Studio Replicator.

  6. Click Next.

  7. In the Open dialog, select the hierarchy information file to use and click Open.

  8. Proceed to the next step (see Section B.8.3, "Step 3: Selecting Items to Replicate").

B.8.3 Step 3: Selecting Items to Replicate

After you select your source and target servers (or project files), the next screen opens, where you can select individual sections, custom properties, and asset categories to replicate. You can also override any environment properties on the site.

The source hierarchy appears in the Site Hierarchy pane on the left, and the merged hierarchy appears in the Preview pane on the right. For more information, see Section A.82.3, "Step 3: Select Items to Replicate."

To select items to replicate, perform these tasks:

  1. In the Site Hierarchy pane, check the boxes beside the desired sections, custom properties, and asset categories you want to replicate.

    The first time you replicate a site, you see the complete site hierarchy (including the root) in the Preview pane, even though nothing has been selected yet on the source. You still must select the site hierarchy and root section on the source in order for the site hierarchy to replicate.

  2. Click Advanced and choose an option for replicating your hierarchy:

    • Choose Replicate the selected folders to replicate individual sections of your site.

    • Choose Replicate the entire source hierarchy to replicate the entire site.

      Note:

      Replicating the entire hierarchy is common if this is the first time you are replicating the site. The next time you replicate, you would choose selected folders.
    • Click Override Environment Properties to override the environment settings you made in the Environment Properties dialog in Designer (see Section B.8.6, "Overriding Environment Properties").

    • Check Preserve the target's switched region associations to preserve the content that contributors switched on the target server and therefore prevent it from being overwritten.

      Click OK to return to Oracle Site Studio Replicator.

  3. To view the current properties for a particular section (on the source or target server), right-click that section and choose Properties.

    This opens the Properties dialog.

    Figure B-9Properties Dialog

    Properties Dialog

    With this window open, you can continue clicking on different sections of the site hierarchy to view the properties for that section.

  4. To remove a section from the target server, right-click that section and choose Delete.

    Deleting a section from the target server is useful when a section is no longer needed, or it has been moved to another part of the site.

  5. Click Next and proceed to the next step (see Section B.8.4, "Step 4: Completing Oracle Site Studio Replicator").

You can resize this dialog to see more of your site hierarchy.

When you select a web site at the top-level or a section at the top-level, every section below it is replicated.

If you select a subsection on the source server, then the parent of that subsection must already exist on the target server. If not, you receive a message stating that the selected hierarchies could not be merged because there is no parent in the target hierarchy. To resolve, you must select the parent section of the one you're replicating on the source hierarchy.

A section that appears in bold on the target hierarchy (Preview pane) indicates that it is a section that is created during the replication process.

B.8.4 Step 4: Completing Oracle Site Studio Replicator

After you select your source and target servers (or project files) and have selected items to replicate, the next screen opens, where you can confirm your choices and replicate the site hierarchy.

On this screen, you see the location and URL of both the source and target servers, the replication type, and the site hierarchies to be replicated. For more information, see Section A.82.4, "Step 4: Perform Replication."

To replicate the site hierarchy, perform these tasks:

  1. Click Preview to see the site hierarchy changes that takes place on the target server. When finished, click Close.

  2. Click Finish.

  3. Click Yes to the message asking to replicate to the target server.

  4. If you are creating a site on the target server, you are taken to the Assign Info Form where you specify the metadata that is assigned to the project file.

    When finished, click Assign Info.

  5. Click OK to the confirmation message.

If this is the first time you are replicating your site, then return to the Manage Site Replication page to complete the replication (see Section B.5, "Starting the Site Replication").

B.8.5 Modifying Server Connections

When you select a server as a source or target location, you can change the properties of an existing server, add a server, and delete a server.

Adding a New Server to the List

To add a server to the list, perform these tasks:

  1. When specifying a source or target server in Oracle Site Studio Replicator, click the Additional Information icon (Figure B-10).

    Figure B-10Additional Information Icon

    Additional Information Icon
  2. Click Add Server.

  3. In the Server Configuration dialog, enter the name for the server in the Server Name field (this is what opens the next time you choose a server).

  4. Enter the URL of the server in the CGI URL field.

    Typically, you can use the existing URL provided in the field, replacing server with the name of your server.

  5. Click OK.

Removing a Server From the List

To remove a server from the server list, perform these tasks:

  1. When specifying a source or target server in Oracle Site Studio Replicator, select the server you want to remove, and then click the Additional Information icon (Figure B-11).

    Figure B-11Additional Information Icon

    Additional Information Icon
  2. Click Remove Server.

  3. Click Yes to the confirmation message asking you to remove the server from the list.

Viewing or Editing a Server's Properties

To view or edit a server's properties, perform these tasks:

  1. When specifying a source or target server in Oracle Site Studio Replicator, select the server you want to view or edit, and then click the Additional Information icon (Figure B-12).

    Figure B-12Additional Information Icon

    Additional Information Icon
  2. Click Properties.

  3. In the Server Configuration dialog, you can view or edit the properties of the server.

  4. Click OK.

B.8.6 Overriding Environment Properties

After you've specified environment properties for your site in Designer (see Section B.6, "Specifying Environment Properties"), you can later override those settings when you replicate the site.

You do this in the Override Environment Properties dialog, which is located in Oracle Site Studio Replicator (see Section B.8.3, "Step 3: Selecting Items to Replicate").

To override environment properties, perform these tasks:

  1. On the Selecting Items to Replicate screen in Oracle Site Studio Replicator, click Advanced.

  2. In the Advanced dialog, click Override Environment Properties.

  3. Check the box beside the property to treat as an environment property.

    Or, clear the box beside the property to treat it as an application property.

  4. Click OK to return to Oracle Site Studio Replicator and complete the replication.