Running the ignite visor in Kubernetes

7/19/2017

Has anyone had any luck running the Ignite visor in a Kubernetes environment? Should it be run from its own pod? Would I need to open extra ports or configure the ignite service differently? So far I have had no luck, but my experience with Ignite is fairly shallow.

-- CyrusK
ignite
kubernetes

2 Answers

8/8/2017

To run Ignite Visor in Kubernetes you need to configure it absolutely the same as simple Ignite nodes, it means that you need to configure DiscoverySpi and CommunicationSpi.

Here is a link to documentation with configuration of Ignite in Kubernetes environment: https://apacheignite.readme.io/docs/kubernetes-deployment

-- Evgenii Zhuravlev
Source: StackOverflow

4/13/2018

In Kubernetes you have to use only one the same network port for all Apache Ignite instances including Visor, instead of port range, for discovery and communication between instances [1]. This happens because you cannot expose a port range for POD in k8s. Moreover, you have to be sure that instances in the cluster see each other, so you have to use special discovery SPI. By default, if you start Visor in the POD where you have one instance already started, then Visor cannot obtain the same port and uses another from a range, and as a result it doesn't see other nodes in the cluster or see only one node in the POD where it has been started.

If this is the case, then I'd recommend to start a separate POD with the same config but with another CMD, which doesn't start a server node, but runs a sleep loop instead, in order that k8s won't kill the POD. Then you can kubectl exec -ti pod-id -- bash and start the Visor/Sqlline/Control with the same config that you've provided for other instances.

[1] https://apacheignite.readme.io/docs/network-config

Hope it will help.

-- Arseny Kovalchuk
Source: StackOverflow