Here is a brief overview of the steps involved in setting up an Integration Repository:
Create and configure an Integration Repository. This is a component of class
atg.adapter.integrations.IntegrationRepository
. Configure the properties described in the IntegrationRepository section.Create the Integration Repository’s definition file, as described in the Defining an Integration Repository section.
Create and configure your local repository. The local repository is a normal SQL repository. See SQL Repository Overview in the Repository Guide for more information.
Create the database schema for your local repository.
Create any mapping files you desire for each item descriptor in the Integration Repository. See Mapping for more information.
Create a subclass of
IntegrationRepositoryView
for each remote system you need to query.Create
Commands
that correspond to each of the command operations you want to define for your Integration Repository. See the Remote Procedure Calls chapter.
To set up a complete integration with a remote system, you will also need to perform many tasks that are outside the scope of this chapter. You will need to configure the transport layer that connects the Oracle Commerce Platform to the remote system. You will also typically want to create a portlet (ATG Portal gear) or set of form pages to display and modify data from the remote system.
Defining an Integration Repository
The Integration Repository is defined by an XML template file. This file is specified by the definitionFile
property of the IntegrationRepository
component. The Integration Repository definition file defines the integration behavior, including the commands used for the executeQuery
, getItem
, createItem
, updateItem
, and removeItem
integration operations. The elements of the Integration Repository definition file are described in the Integration Repository Definition File section. The commands are described in the Command Operations section.
Since the Integration Repository wraps another repository, the underlying SQL repository also requires a definition file to define the repository item properties. You may also want to create mapping files to handle the relation of your repository item properties to the data maintained on the remote system. See the Web Services Guide for more information.
This is an example of what the Integration Repository definition file would look like. It defines a single item descriptor, named account
, and specifies the Commands
used to query, get, add, update, and remove account
items:
<integration-repository-template> <header> <name>RemoteX Repository</name> </header> <item-descriptor name="account"> <query command="/atg/integrations/remotex/queries/AccountQuery" view="atg.integrations.remotex.RemoteXView"> </query> <get-item command="/atg/integrations/remotex/queries/AccountQuery"> </get-item> <add-item command="/atg/integrations/remotex/queries/AccountUpdateRPC"> </add-item> <update-item command="/atg/integrations/remotex/queries/AccountUpdateRPC"> </update-item> <remove-item command="/atg/integrations/remotex/queries/AccountDeleteRPC"> </remove-item> </item-descriptor> </integration-repository-template>
The Integration Repository is also configured using normal JavaBean properties. An IntegrationRepository
component might be configured in a properties file like this:
$class=atg.adapter.integrations.IntegrationRepository repositoryName=MyStuff localRepository=/mystuff/MyLocalRepository definitionFile=/mystuff/irConfig.xml transactionManager=/atg/dynamo/transaction/TransactionManager integrationRepositoryTools=/atg/integrations/repository/IntegrationRepositoryTools persistentCacheManager=/atg/integrations/repository/PersistentCacheManager mappingManager=/atg/repository/xml/SchemaManager mappingTools=/atg/integrations/repository/MappingTools lockManager=/atg/dynamo/service/ClientLockManager
The IntegrationRepository section describes these properties.