Adding Elasticsearch indexes for Experience Optimization

To set up your Elasticsearch instance for Experience Optimization , run an installation script to create the Elasticsearch indexes in your Elasticsearch database. The process includes creation of a default set of Trigger Types for use with Experience Optimization Promotions. You can subsequently customize these, as needed.

Before you begin

To run these scripts, you must have set up Elasticsearch and you must have its host name, port number, and valid connection credentials available.

Procedure

  1. Do one of the following:
    • If you are installing on a Windows environment, open a PowerShell command shell.
    • If you are installing on a Unix environment, open a Unix command shell.
  2. Navigate to the installation media folder Content Delivery\roles\xo\resources\elasticsearch\.
  3. Do one of the following:
    • If you are installing on a Windows environment, enter .\installElasticSearchIndexes.ps1 but do not yet press Enter.
    • If you are installing on a Unix environment, enter .\installElasticSearchIndexes.sh but do not yet press Enter.
  4. Add command line switches, with values, to your command as needed.

    The following table describes the parameters you typically need to set:

    ParameterValue descriptionDefault if not specified

    es-index-common-name-prefix

    A prefix to be used with the index name

    none

    es-host

    The host on which your Elasticsearch instance runs

    localhost

    es-port

    The port on which your Elasticsearch instance runs

    9200

    es-username

    If the Elasticsearch instance is secured, the name of a user who can access the Elasticsearch instance

    none (Elasticsearch instance is not secured)

    es-password

    If the Elasticsearch instance is secured, the password of the user above

    none (Elasticsearch instance is not secured)

    es-scheme

    Indicates whether Elasticsearch will connect over the HTTP protocol or the secure HTTPS protocol.

    http

    es-ingest-username

    If you connect to the Elasticsearch instance through Basic Authentication (typically to connect to an external Elasticsearch like Elastic Cloud), the name of a user who can access the Elasticsearch ingest node

    none (no Basic Authentication set up for the Elasticsearch instance)

    es-ingest-password

    If you connect to the Elasticsearch instance through Basic Authentication, the password of the user above

    none (no Basic Authentication set up for the Elasticsearch instance)

  5. Press Enter.
    The script creates the indexes.

Results

Your Elasticsearch is configured with a default set of Trigger Types that can be used with Experience Optimization Promotions.

What to do next

If you have need for additional, custom Trigger Types, add those using the provided Powershell cmdlets.