High Availability with System Monitoring Services

Description: EnterWorks includes an active system health monitoring service to support high availability environments. It enables you to achieve fault tolerance in your applications, seamlessly providing for Active/Passive and Active/Active high availability architectures. There are a series of system status checks that monitor the instance and any components that are necessary for the instance to function. These checks look at a number of measures, including network connectivity performance, physical software crashes, and hardware functionality. For Active/Passive environments, downtime could be minimal if additional automation is used to start the Passive server stack.

EnterWorks Product Applicability: EnterWorks 10+ versions

Third Party Product: Load Balancer Service

Deployment Architecture

The primary EnterWorks environment is augmented with the installation of one or more redundant service paths (Tomcat host services). The services should be deployed on separate host environments. A load balancer is deployed as the common application endpoint address and configured for sticky sessions in order to support session-based synchronous operations.

Configuration Guidance for new deployments of Health Check with EnterWorks

Health Check URL/Services: {host}/enable-diagnostics/heartbeat

This returns a URL that will return an http response code of 200 if system health is okay. If any configured designated services are not available, it will return a 400 error.

Configuration file path:

<drive>:\Enterworks\enable2020\services\install\create-enable-web-server-service.cmd

The create-<service-name>-service.cmd scripts should exist in the following folder. If they do not, create the create-service scripts.

<drive>:\Enterworks\enable2020\services\install

Configuration:

  1. The EnterWorks diagnostics service uses the healthCheckComponents flag. This flag is a comma separated field which identifies the components that are labeled critical. The components are identified by the ComponentName flag. The default names are below.
    * webcm-Broker * enable-api-service
    * enable-channel-readiness-service * enable-dam-magick-service
    * enable-dam-manager-service * enable-dam-monitor
    * enable-epx-broker * enable-es-indexer-service
    * enable-es-manager-service * enable-es-search-service
    * enable-mq-logger  
  2. Example Configuration Entry:
healthCheckComponents=webcm-Broker,enable-api-service,enable-channel-readiness-service,enable-dam-magick-service,enable-dam-manager-service,enable-epx-broker,enable-es-indexer-service,enable-es-manager-service,enable-es-search-service,enable-mq-logger,tomcat-epim

Note: Tomcat is a special situation where the webserver must have the enableEnableProxy flag set to true in order to monitor tomcat-epim.

Configuration Guidance for adding Health Check to an existing deployment of EnterWorks

Best practice: When creating custom start and stop scripts, call the EnterWorks provided scripts from within any customer scripts.

Adding the Flag to the Script Used to a Create EnterWorks Web Service Command Script

  1. Open the create-enable-web-server-service.cmd in a text editor.
  2. Add the following flag:
    -healthCheckComponents=Webcm-Broker,enable-api-service
    as shown at the bottom of the example below.
    NET STOP enable-web-server-service
    sc delete enable-web-server-service
    sc create enable-web-server-service binpath=^"D:\Enterworks\enable2020\services\bin\enable2020-web-server-service.exe ^
    -rabbitServer=enable2020:enable2020@<host> ^
    -epimHost=<host>:8090 ^
    -port=80 ^
    -cliBuildFolder=D:\Enterworks\enable2020\enable2020 ^
    -uploadFolder=D:\Enterworks\enable2020\services\uploads ^
    -epxHost=<host> ^
    -sessionDbFile=D:\Enterworks\enable2020\sessions\enable2020-session.db ^
    -loggingLevel=INFO ^
    -logDir=D:\Enterworks\logs\enable2020 ^
    -exchange=enable2020 ^
    -esBrokerQueue=elasticSearchBroker ^
    -webcmBrokerQueue=webcmBrokered ^
    -enableDamQueue=enableDam ^
    -enableApiQueue=enableApi ^
    -channelReadinessQueue=enableChannelReadiness ^
    -epxBrokerQueue=epxBrokerQueue ^
    -disableAdmin=false ^
    -disableReport=false ^
    -disableSystem=false ^
    -customProxies=/language;https://translation.googleapis.com ^
    -customPaths=/custom;D:/Enterworks/enable2020/custom ^
    -healthCheckComponents=Webcm-Broker,enable-api-service"
    pause
    
  3. Use the create-enable-web-server-service.cmd script, (see Using a create-service Script).
  4. Open the Services window and restart the enable-web-server-service.