Get the endpoint results of all nodes in a cluster

5/17/2018

I am using Kubernetes service to send certain data say, the list of fuse mount points of each worker. When I call the REST API , the service will list the endpoint details of a particular worker node. Is there any way I can get the details of all the worker nodes in one single service endpoint.

router.GET("/get", GetMountResult)

The above code post the result to a particular endpoint using below code

   go func() {
    fmt.Println("API Call")
    router.Run(":" + port)
}()

In GetMountResult I just put the final result

filelogger.Info("List of mount points:", zap.Any(" ", finalmap))
c.JSON(200, finalmap)
-- ambikanair
endpoint
kubernetes
rest
service

0 Answers