How to configure a health check for the TIBCO Spotfire Server when using a load balancer.

How to configure a health check for the TIBCO Spotfire Server when using a load balancer.

book

Article ID: KB0080405

calendar_today

Updated On:

Products Versions
Spotfire Server All Versions

Description

When using a load balancer in front of the TIBCO Spotfire Server, you may want to configure a health check in the Load Balancer to confirm the TIBCO Spotfire Server is available before it routes requests.This can be accomplished with Spotfire with a URL based health check which can be used to check for a valid HTTP response.

Issue/Introduction

How to configure a health check for the TIBCO Spotfire Server when using a load balancer.

Resolution

For versions 7.5 and higher:
Enable the health check URL per the documentation reference Enabling health check URL for load balanced servers.



For versions 7.0 and lower:

OPTION 1:
Have the load balancer health check use the URL:  http://your-spotfire-server:port/spotfire/index.jsp and verify that you receive a successful HTTP response.

OPTION 2:
There may be load balancers which are hard-coded to require a specific URL format for the health check URL which does not match the URL used in the Option 1 and Option 2. For example, perhaps the load balancer requires a health check URL such as: '/healthcheck'. In this case, manually add a /healthcheck/ folder (with an index page in it) under <installation directory>\tomcat\webapps\spotfire\ . Note however that the new URL must be added to the security-filter.xml file, which is located under <installation directory>\spotfire\WEB-INF.

Example:
 <security-config>
    <security-constraint>
      <display-name>open</display-name>
      <web-resource-collection>
        <web-resource-name>Open Resources</web-resource-name>
        <description>Resources accessible by anyone, including non-authenticated clients</description>
        <url-pattern>/</url-pattern>
        <url-pattern>/about.jsp</url-pattern>
        <url-pattern>/error.jsp</url-pattern>
        <url-pattern>/favicon.ico</url-pattern>
        <url-pattern>/index.jsp</url-pattern>
        <url-pattern>/logout.jsp</url-pattern>
        <url-pattern>/manifest</url-pattern>
        <url-pattern>/serverstatus</url-pattern>
        <url-pattern>/shared/*</url-pattern>
        <url-pattern>/support/getusername</url-pattern>
        <url-pattern>/support/manuals/*</url-pattern>
        <url-pattern>/ws/dsp/lib/viewer/*</url-pattern>

        <!-- Add something like this -->
        <url-pattern>/healthcheck/index.html</url-pattern>


        <http-method>GET</http-method>
        <http-method>POST</http-method>
      </web-resource-collection>
      <!-- No auth-constraint -->
    </security-constraint>
    <!-- No login-config -->
  </security-config>

OPTION 3:
Have the load balancer health check use the URL  http://your-spotfire-server:port/spotfire/serverstatus?ping and if the Spotfire Server is alive it will return the text 'pong'.



 

Additional Information

Doc (versions 7.5 and higher only): Enabling health check URL for load balanced servers