An EndecaIndexingOutputConfig indexing definition file begins with a top-level item element that specifies the item descriptor to create records from, and then lists the properties of that item type to include. The properties appear as property elements within a properties element.

The top-level item element in the definition file can contain child item elements for properties that refer to other repository items (or arrays, Collections, or Maps of repository items). Those child item elements in turn can contain property and item elements themselves.

The following example shows a simple definition file for indexing an ATG product catalog repository:

<item item-descriptor-name="product" is-document="true">
  <properties>
    <property name="creationDate" type="date"/>
    <property name="brand" is-dimension="true" type="string"
      text-searchable="true"/>
    <property name="description" text-searchable="true"/>
    <property name="longDescription" text-searchable="true"/>
    <property name="displayName" text-searchable="true"/>
  </properties>

  <item is-multi="true" property-name="childSKUs">
    <properties>
      <property name="quantity" type="integer"/>
      <property name="description" text-searchable="true"/>
      <property name="displayName" text-searchable="true"/>
      <property name="color" is-dimension="true" type="string"
         text-searchable="true"/>
    </properties>

  <item is-multi="true" property-name="parentCategories"
      parent-property="childProducts">
    <properties>
      <property name="description" text-searchable="true"/>
      <property name="longDescription" text-searchable="true"/>
      <property name="displayName" text-searchable="true"/>
    </properties>
  </item>
</item>

Note that in this example, the top-level item element has the is-document attribute set to true. This attribute specifies that a record should be generated for each item of that type (in this case, each product item). This means that each record indexed by Oracle Endeca Commerce corresponds to a product, so that when a user searches the catalog, each individual result returned represents a product. The definition file specifies that each output record should include information about the product’s parent categories and child SKUs (as well as the product itself), so that users can search category or SKU properties in addition to product properties.

If, instead, you want to generate a separate record per sku item, you set is-document to true for the childSKUs item element and to false for the product item element. In that case, the product properties (e.g., brand in the example) are repeated in each record.

When you configure the ATG-Endeca integration in CIM, you select whether to index by product or SKU. Your selection determines whether certain application modules are included in your EAR files. These modules configure the is-document attributes and other related settings appropriately for the option you select. See ATG Modules for information about these modules.

In addition to the properties you specify in the definition file, the output records also automatically include a few special properties. These properties provide information that identifies the repository items represented in the record: repositoryId, repository.repositoryName, and itemDescriptor.itemDescriptorName.

The output also includes a url property and a baseUrl property, which each contain the URL representing this repository item. The difference between these properties is that if a VariantProducer is used to generate multiple records from the same repository item, the url property for each record will include unique query parameters to distinguish the record from the others. The baseUrl property, which omits the query parameters, will be the same for each record.


Copyright © 1997, 2012 Oracle and/or its affiliates. All rights reserved.

Legal Notices