Jump to: navigation, search

ha-chat-reconnecting-delay

Section: channel-chatbot
Default Value: 10
Valid Values: Any integer from 0-86400
Changes Take Effect: Immediately for new connections
Introduced: 9.0.005.05

Specifies the delay between attempts when Bot Gateway Server tries to reconnect the bot to the chat session when there is a Chat Server disconnect.

ha-chat-reconnecting-attempts

Section: channel-chatbot
Default Value: 15
Valid Values: Any integer from 0-1000000
Changes Take Effect: Immediately for new connections
Introduced: 9.0.005.05

Specifies how many times Bot Gateway Server tries to reconnect the bot to the chat session when there is a Chat Server disconnect.

ha-chat-reconnecting-delay

Section: channel-chatbot
Default Value: 10
Valid Values: Any integer from 0-86400
Changes Take Effect: Immediately for new connections
Introduced: 9.0.005.05

Specifies the delay between attempts when Bot Gateway Server tries to reconnect the bot to the chat session when there is a Chat Server disconnect.

ha-chat-reconnecting-attempts

Section: channel-chatbot
Default Value: 15
Valid Values: Any integer from 0-1000000
Changes Take Effect: Immediately for new connections
Introduced: 9.0.005.05

Specifies how many times Bot Gateway Server tries to reconnect the bot to the chat session when there is a Chat Server disconnect.

ha-bot-recovery-batch

Section: channel-chatbot
Default Value: 200
Valid Values: Any integer from 1-1000000
Changes Take Effect: Immediately
Introduced: 9.0.006.04

Specifies the number of interactions in a single batch, which BGS fetches from Interaction Server during a bot recovery procedure.

ha-bot-start-unrestricted

Section: channel-chatbot
Default Value: false
Valid Values: true, false
Changes Take Effect: Immediately
Introduced: 9.0.006.04

In the case of starting multiple bots in the same chat session on different pairs of BGS instances, this option permits a bot to start even if HA support for the bot is not possible.

ha-bot-recovery-enabled

Section: channel-chatbot
Default Value: false
Valid Values: true, false
Changes Take Effect: After restart
Introduced: 9.0.006.04

Enables (true) or disables (false, the default) bot recovery mode, when BGS restores bot sessions during startup or switchover to primary mode.

How to deploy Bot Gateway Server

Prerequisites

  • Make sure that your solution deploys the appropriate version of Chat Server (see Compatibility matrix, below).
  • Deploy dedicated instance(s) of Digital Messaging Server (DMS) for Bot Gateway Server (see Compatibility matrix, below). Refer to the Digital Messaging Server 9.0.0 Deployment Procedure for more information.

Compatibility matrix

Component Prerequisites
Chat Server
  • For basic functionality, 8.5.109.06 or higher is required.
  • To enable historical reporting, 8.5.301.06 or higher is required.
  • To enable high availability, 8.5.308.06 or higher is required.
Digital Messaging Server (DMS) For information on compability, see the Digital Messaging Server and Driver Compatibility page in the Genesys Interoperability Guide.
Genesys Mobile Services (GMS)
  • Basic functionality (in other words, plain text messages) is supported the same way as a regular web chat.
  • Rich Media is supported from version 8.5.201.08 and higher.
Widgets
  • Basic functionality (in other words, plain text messages) is supported the same way as a regular web chat.
  • Rich Media support must be tracked by the Widgets Release Notes.
  • A special icon for the bot participant is supported as of version 9.0.014.09.
Workspace Desktop Edition (WDE)
  • Min version 8.5.118.10 or higher is required.
  • A special icon for bot participant is supported from version 8.5.127.06 or higher.


Rich Media:

Deployment

  1. Install the Bot Gateway Server either by manual installation of the IP or via the GAX deployment procedure. During the installation, you'll need to select the previously installed dedicated instance of DMS. The content of the IP will be installed in the folder media-channel-drivers\channel-chatbot.
  2. In file "JavaServerStarter.ini" (located in the root installation folder of DMS), change the value of genesys.mcr.stdserverex.flexchatprotocol and genesys.mcr.stdserverex.chatrequired to false.
  3. In Interaction Server application, add DMS application to connections tab.
  4. To enable high availability support, see High Availability support below.
  5. Using GAX, do the following in the DMS Application object:
    1. Add connection to the following applications:
      1. Interaction Server (required for core functionality)
      2. Universal Contact Server (required for API methods for file attachments and structured messages only).
        Note: If you decide not to use these methods and not connect DMS to Universal Contact Server, you must set ucs-in-use to false.
    2. In the Application Options tab:
      1. Remove the following sections: [channel-any_name], [channel-any_name-monitor-any_name], and [endpoints:tenant_dbid].
      2. Import options from the file BotGatewayServer.cfg (located in the media-channel-drivers\channel-chatbot\options subfolder in the DMS installation folder). You must de-select the check box Overwrite existing options. This step adds sections [channel-chatbot], [channel-chatbot-monitor-addp], and [channel-chatbot-monitor-tls].
      3. In section [channel-chatbot], set the correct value for option tenant-dbid (for example, tenant-dbid=1).
      4. In section [log], add new option log4j2-config-profile with value log4j2.xml (if it doesn't already exist).
    3. Start DMS and observe logs. The following log message indicates success:
      Std 42111 (ChannelConnectors.configure): initialized channel-chatbot
    4. Important
      Please note that while some configuration options which are applicable to new chat session can be updated during runtime, it is generally recommended to restart DMS upon application configuration changes.

How to uninstall or upgrade BGS

To uninstall or upgrade BGS, do the following:

  1. Backup the content of the folder “media-channel-drivers\channel-chatbot\bots-repo”.
  2. Stop the DMS/BGS application. This can be done via GAX (on Windows it can be done via Services).
  3. Uninstall the BGS application:
    • On Windows through Control Panel > Programs and Features.
    • On Linux by running the ./uninstall.sh, script from the "media-channel-drivers\channel-chatbot\uninstall" folder.
  4. Verify that the folder “media-channel-drivers\channel-chatbot" was removed.
  5. Install the new version of BGS and populate the folder “media-channel-drivers\channel-chatbot\bots-repo” from your backup.
  6. Start the DMS/BGS application.

How to test BGS

To test BGS, complete the following steps:

  1. Activate the preinstalled EchoBot:
    1. In the Application Options tab of the DMS Application object, add the section [channel-chatbot-monitor-bots] and option EchoBot.jar={}.
    2. Restart the DMS application.
      Note: Several other bot samples are provided. You can find out how to deploy and use these other sample bots by reading the "readme.txt" file located in "media-channel-drivers\channel-chatbot\samples\demo" of the DMS installation folder.
  2. Deploy the sample workflow (located in the subfolder media-channel-drivers\channel-chatbot\workflow in the DMS installation folder):
    1. Import the business process:
      • either from ChatBotsGoBP.wie (require IRD and URS). Activate strategies.
      • or from ChatBotsGo.zip (requires Composer and ORS). Run Generate All (ignore the error against "RESTProxy.jsp").
    2. If you have more than one DMS instance running (and configured in connections of Interaction Server application), you need to select your Bot Gateway Server application in the External Service block which starts the bot (located in Start strategy).
  1. Launch the Chat Widget with the following userdata:
    { ChatBotID: "EchoBot"
    , ChatBotName: "EchoBot"
    , ChatBotHoldup: "false"
    , StopBotOnAgentArrival: "false"
    , StopBotOnCustomerLeft : "false"
    , Visibility : "ALL"
    , Nickname : "Demo Echo Bot"
    , _umsChannel : "channel-chatbot"
    }
    
  2. As soon as the chat session starts in the Chat Widget, EchoBot connects and it echos every posted message into the chat session. You can stop EchoBot by sending one of the following texts in the chat session:
    stop:keep_alive
    stop:force_close
    stop:close_if_no_agents
    stop
    
  3. Note: In waiting mode (in other words, when ChatBotHoldup=true), with default configuration of holdup-attribute-name (which is “ScheduledAt”) Bot Gateway Server relies on the scheduled interactions functionality of Interaction Server. If this conflicts with your workflow logic, you can set holdup-attribute-name to another value. In this case you will need:

  • To modify Interaction Server database schema and create correspondeing interaction custom property of type “timestamp” (refer to Custom Properties in the eServices Interaction Properties Reference Manual).
  • To specify view condition in “Waiting” queue instead of using “Scheduling” (which then must be set to “Ignore Scheduling”).

High availability and sizing guidelines

High Availability support

High availability (HA) support consists of the following functional areas:

Area Deployment Notes
Bot restoration after BGS switchover The following must be done:
  1. Add a special custom interaction attribute which is used by BGS for the interactions' content query in HA mode. For that:
    1. Stop Interaction Server.
    2. Upgrade the Interaction Server Database (execute script ha_support_<database name>.sql from the ha_sql_scripts folder).
    3. Create a new interaction custom property. In Configuration (using GAX):
      1. Navigate to the Business Attributes folder and find (or create) a new Business Attribute with:
        • type: Custom
        • name: InteractionCustomProperties
        • display name: Interaction Custom Properties
      2. Navigate to the Attribute Values of InteractionCustomProperties and create a new value with the name and display name of GCTI_BGS_AppName and a [translation] section in the Annex tab with the option translate-to and value of bgs_app_name.
    4. Start Interaction Server.
  2. Create two BGS applications and configure those as the primary/backup pair.
  3. For each application (primary and backup), set the configuration option ha-bot-recovery-enabled with the value of true. Optionally, revise if you need to adjust the values for options ha-bot-start-unrestricted and ha-bot-recovery-batch.
Bot context saving and restoring Ensure that Chat Server (minimum version 8.5.308.06) is deployed in HA mode so the bot context will be preserved as a part of the chat session transcript in UCS or Cassandra.
Reconnection to chat session BGS supports the automatic (seamless) reconnection to the chat session in the case of a Chat Server failure. Revise the chat session reconnect schedule defined in the configuration options ha-chat-reconnecting-attempts and ha-chat-reconnecting-delay. Genesys recommends deploying HA for Chat Server in N+1 (load-balancing) mode, along with adjusting a few configuration options as described in the topic, Configure Chat Server for HA.
Reconnection to Interaction Server and UCS Reconnection to Interaction Server and UCS is defined via a standard application connection configuration.


Note: UCS connection is needed only for Rich Media and attachments functionality. In order for the reconnection to Interaction Server and UCS to be enabled, these applications must be configured as a primary/backup pair

Sizing guidelines

For High Availability (HA) support, no special configuration on BGS side is required, unless you need to define a different chat session reconnect schedule with configuration options ha-chat-reconnecting-attempts and ha-chat-reconnecting-delay. BGS supports the automatic (seamless) reconnection to the chat session in case of a Chat Server failure, and it also handles the reconnection to Interaction Server and UCS (the later is needed only for Rich Media and attachments functionality). In order for the reconnection to Interaction Server and UCS to be enabled, these applications must be configured with a primary/backup pair. Genesys recommends deploying HA for Chat Server in N+1 (load-balancing) mode, along with adjusting a few configuration options as described in the topic, Configure Chat Server for HA.

For BGS, the following performance benchmarks were obtained on hardware with "Intel Xeon E7-8880L 2 GHz" and a single instance of Bot Gateway Server. The average length of a chat session was around 55 seconds (with 5 short messages from a customer and 5 short messages from an agent), which is a quite dense scenario. A single instance of BGS was capable of maintaining around 2500 concurrent bot sessions while consuming about 2 CPU cores and 3 GB of RAM. With this given scenario, on-average about 50 new bots started every second. hen planning the deployment, the chat session density (in other words the number of messages from or to a bot, each second) and the bot startup rate (how many new bots start, each second) play a significant role in the BGS performance benchmarking.

Configure secure and ADDP connections

You can configure the following secure and ADDP connections:

Connection Configuration
  • DMS to Configuration Server
  • DMS to Message Server
  • DMS to Interaction Server
  • DMS to Universal Contact Server
  • Interaction Server to DMS
Use standard Genesys approach to provide TLS configuration on hosts, applications, ports, and ADDP parameters in connections
DMS/BGS to Chat Server Use a special approach described below.

Secure connection to Chat server

When connecting a bot instance to a chat session, Bot Gateway Server connects to the host/port which is specified in the userdata of the interaction as ChatServerHost/ChatServerPort. If a port is configured as secure, Chat Server also attaches ChatServerConnType=tls. When Bot Gateway Server detects this property in the userdata, it tries to establish a secure connection. To configure these secure connections, you need to use section [channel-chatbot-monitor-tls] of the DMS application:

  1. Set option provider to a desired security provider (see description of options for more information). By default, a provider is set to ANY, which will allow you to establish a secure connection without using any certificate. This mode is recommended for testing purposes only.
  2. Configure option trusted-ca with corresponding certificate.
  3. Review and configure (if needed) all other options in this section.
    Note:

ADDP connection to Chat server

Use section [channel-chatbot-monitor-addp] in order to configure ADDP connection to Chat Server.

Enable Reporting for BGS

Genesys Historical Reporting Solution provides reports about chat bots that are run by BGS. The reporting solution consumes reporting data from BGS via Kafka integration. For full information, see Integrating BGS with Genesys Historical Reporting.

This page was last edited on February 22, 2022, at 16:47.
Comments or questions about this documentation? Contact us for support!