Sending requests to Apinizer's core modules and seeing their status and version will provide useful information in many cases.

For this, you must first connect to the Master server with an authorized user, identify the relevant pods and their status.

As an example, we run our first command as can be seen in the image below:

kubectl get pods -A
CODE


This will output all the pods on your system. In this example, all pods are working properly:


In addition, knowledge of the services that perform the communication of the running pods is also required.

kubectl get svc -A
CODE


Sample output:


The Apinizer Interface (Manager) is run on the "apinizer" namespace by default.

If you do not have a special preference, the default namespaces for Apinizer Gateways (worker and cache) are also set to "test" or "prod".

In this example, the Apinizer Integration and Apinizer Portal modules also appear in the "apinizer-integration" and "apinizer-portal" namespaces.

With this information and the commands below, the URL can be created as follows to see if the desired application is working.


http://SERVICENAME.ENVIRONMENTNAME.svc.cluster.local:SERVICEINTERNALPORT/apinizer/management/health

http://manager.apinizer.svc.cluster.local:8080/apinizer/management/health
CODE


However, existing servers will not be able to resolve these dns managed in kubernetes on their own.

With the help of the command below, you can send a request to the address you want from a working pod.

The pod's information can be taken from the output in the first screenshot above.

kubectl exec -it ANYPODNAME -n PODSNAMESPACE -- curl apinizer.com
CODE


If it is desired to go directly through the server, direct access can be obtained by getting the information on which ip of the relevant service from the output in the second screenshot above, and by typing the ip of the relevant pod instead of the name in the first part.

http://10.106.93.12:8080/apinizer/management/health
CODE



In summary, when installed with default settings, Health and Version control of each module can be done as follows, according to the information taken from the screenshots above.

Manager:

kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://manager.apinizer.svc.cluster.local:8080/apinizer/management/health

curl -X GET http://10.106.93.12:8080/apinizer/management/health
CODE


kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://manager.apinizer.svc.cluster.local:8080/apinizer/management/version

curl -X GET http://10.106.93.12:8080/apinizer/management/version 
CODE


Worker:

kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://worker-http-service.prod.svc.cluster.local:8091/apinizer/management/health

curl -X GET http://10.96.41.117:8091/api/health
CODE
kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://worker-http-service.prod.svc.cluster.local:8091/apinizer/management/version

curl -X GET http://10.96.41.117:8091/apinizer/management/version
CODE

Cache:

kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://cache-http-service.prod.svc.cluster.local:8090/apinizer/management/health
CODE
kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://cache-http-service.prod.svc.cluster.local:8090/apinizer/management/version
CODE


Integration:

kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://integration-http-service.apinizer-integration.svc.cluster.local:8092/apinizer/management/health
curl -X GET http://10.99.227.21:8092/apinizer/management/health
CODE
kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://integration-http-service.apinizer-integration.svc.cluster.local:8092/apinizer/management/version
curl -X GET http://10.99.227.21:8092/apinizer/management/version
CODE


Portal:

kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://apinizer-portal-service.apinizer-portal.svc.cluster.local:8080/apinizer/management/health
curl -X GET http://10.107.79.193:8080/apinizer/management/health
CODE
kubectl exec -it manager-7695978796-q78fx -n apinizer -- curl -X GET http://apinizer-portal-service.apinizer-portal.svc.cluster.local:8080/apinizer/management/version
curl -X GET http://10.107.79.193:8080/apinizer/management/version
CODE