API Gateway: Using a customized health check / ping status page
search cancel

API Gateway: Using a customized health check / ping status page


Article ID: 42852


Updated On:


STARTER PACK-7 CA Rapid App Security CA API Gateway




There is sometimes a requirement for a further customized health check / ping status page than what is provided out-of-the-box for monitoring capabilities of the API Gateway. The attached policy (pinghealth.xml) is an example policy that can use to create a customized health check status page for such an environment.

About the policy

The policy includes a context variable called "disabledHost" which represents a node's FQDN. This context variable is then used later in the policy. An "At least one assertion must evaluate to true" folder is beneath the context variable. It then holds two more folders which are "All assertions must evaluate to true". In the first folder, it compares the variable to see if it contains the value of the ${request.tcp.localhost} variable, and if it does then it passes with a particular response. If it does not pass, then it moves to the last folder in which it returns a different response.

<Please see attached file for image>


How to use

Attached to this article is an example policy that can be used in-place or further customized to meet the needs of a custom health check for an environment. To use this policy, perform the following steps:
  1. Download the attached XML file titled "pinghealth.xml" to a workstation.
  2. In Policy Manager, create the new web API policy to be used for this new health check status page.
  3. While viewing the newly created policy, click the Import Policy button and choose the file that was downloaded in step one above.
  4. Customize the various fields needed by the environment, such as the value of the "disabledHost" context variable.
For the out-of-the-box health check / ping status page, please refer to the Layer 7 Installation and Maintenance Manual.



Component: APIGTW


1558722719179000042852_sktwi1f5rjvs16wjv.jpeg get_app
1558534517295TEC0000001338.zip get_app