Cleaning up the cluster_info table automatically .
search cancel

Cleaning up the cluster_info table automatically .

book

Article ID: 226369

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

While configuring the (Docker) container Gateway, the docker service was restarted a few times and that created lots of container IDs in the cluster_info table of the SSG database.

These invalid containers are also showing up in the policy manager dashboard.

Environment

All Supported Releases of API Gateway.

Resolution

The Gateway has a process that cleans up this cluster_info table at regular intervals.

This interval has a default value of 90 days and it can be configured by the "com.l7tech.server.clusterStaleNodeCleanupTimeoutSeconds" in the system.properties file.

This cleanup  is triggered by a scheduled job which runs every 3600 sec so setting this to a lower value as 3600 sec will not work .

You can add this setting to the YAML file for docker containers.

The other option is to clear the entries manually from the cluster_info table in the Gateway MySQL database when needed.

  • (Verify the current data) select * from cluster_info;
  • (remove all and restart the Gateway service to get the new info) delete from cluster_info;
  • You can also use MySQL queries to remove the invalid info from this table if you know them.