Skip to main content

General Approach

You can perform healthcheck and version checks for Apinizer modules using two main methods:
Performed by sending requests through internal service names using the curl command from a pod within the cluster. This method is ideal for diagnosing intra-cluster communication problems.

Checks from Within Kubernetes

With this method, you can check the accessibility and status of Apinizer modules over the internal network within the Kubernetes cluster.

Pods and Their Status

Check all Pods in the cluster and their status:
kubectl get pods -A
This command outputs all pods in your system. In the example below, all pods are running healthily: Kubernetes Pod Status
In the output, you can see that all Pods are in Running status and the READY column is 1/1. This indicates that the pods are healthy.

Service Information

Check the information of Services that enable communication between Pods:
kubectl get svc -A
Sample output: Kubernetes Service Status The following table shows the service information for Apinizer modules:
ModuleService NameService TypeNamespaceInternal PortExternal Port (Exposed)
ManagermanagerNodePortapinizer808032080
Workerworker-http-serviceNodePortprod809130080
Cachecache-http-serviceClusterIpprod8090-
Integrationintegration-http-serviceNodePortapinizer-integration809230088
Portalapinizer-portal-serviceNodePortapinizer-portal808032090
Based on this information, URLs can be created in the following template and checked by sending curl from any pod within Kubernetes:
http://<SERVICE_NAME>.<NAMESPACE>.svc.cluster.local:<SERVICE_INTERNAL_PORT>/apinizer/management/health

Module-Based Checks

Healthcheck:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://manager.apinizer.svc.cluster.local:8080/apinizer/management/health
Version Information:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://manager.apinizer.svc.cluster.local:8080/apinizer/management/version
Healthcheck:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://worker-http-service.prod.svc.cluster.local:8091/apinizer/management/health
Version Information:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://worker-http-service.prod.svc.cluster.local:8091/apinizer/management/version
Healthcheck:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://cache-http-service.prod.svc.cluster.local:8090/apinizer/management/health
Version Information:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://cache-http-service.prod.svc.cluster.local:8090/apinizer/management/version
Healthcheck:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://integration-http-service.apinizer-integration.svc.cluster.local:8092/apinizer/management/health
Version Information:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://integration-http-service.apinizer-integration.svc.cluster.local:8092/apinizer/management/version
Healthcheck:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://apinizer-portal-service.apinizer-portal.svc.cluster.local:8080/apinizer/management/health
Version Information:
kubectl exec -it <any_pod_name> -n <namespace> -- curl -X GET http://apinizer-portal-service.apinizer-portal.svc.cluster.local:8080/apinizer/management/version

Checks from Outside Kubernetes

If your Apinizer modules are configured to be accessible from outside Kubernetes (for example, services of type NodePort, LoadBalancer, or through an Ingress Controller), you can send requests directly using an HTTP client like Postman or curl from your local terminal. Kubernetes Service Status For Apinizer modules’ services exposed externally with NodePort service type, access can be provided from any client through Kubernetes Node IP addresses and Node Ports. The following table presents the details of Apinizer services:
ModuleService NameService TypeNamespaceInternal PortExternal Port (Exposed)
ManagermanagerNodePortapinizer808032080
Workerworker-http-serviceNodePortprod809130080
Cachecache-http-serviceClusterIpprod8090-
Integrationintegration-http-serviceNodePortapinizer-integration809230088
Portalapinizer-portal-serviceNodePortapinizer-portal808032090

Module-Based Checks

Healthcheck:
curl "http://<MANAGER_ACCESS_URL>/apinizer/management/health"
Version Information:
curl "http://<MANAGER_ACCESS_URL>/apinizer/management/version"
Healthcheck:
curl "http://<WORKER_ACCESS_URL>/apinizer/management/health"
Version Information:
curl "http://<WORKER_ACCESS_URL>/apinizer/management/version"
Healthcheck:
curl "http://<INTEGRATION_ACCESS_URL>/apinizer/management/health"
Version Information:
curl "http://<INTEGRATION_ACCESS_URL>/apinizer/management/version"
Healthcheck:
curl "http://<PORTAL_ACCESS_URL>/apinizer/management/health"
Version Information:
curl "http://<PORTAL_ACCESS_URL>/apinizer/management/version"
Cache Module: The Cache module is not exposed externally by default in installations (ClusterIP service type). Therefore, if you want to perform health-check and version-check directly from outside Kubernetes, the Cache service’s port 8090 must be configured to be accessible externally.