Database Reference
In-Depth Information
High availability of the Storm cluster
Now let's see the demonstration of a failover or high availability in Storm. The Storm
framework is built in such a way that it can continue to execute as long as:
• It has the required number of Zookeeper connections
• It has the required number of workers on one or more supervisors
So what do the preceding statements actually mean? Well, let's understand this with an ex-
ample. Let's say I am executing the WordCount topology on a Storm cluster. This cluster
has the following configuration:
• There are two Storm supervisors with four workers on each Storm supervisor, so a
total eight workers in the cluster
• There are three Zookeeper nodes (max connections 30), so in total 30*2*3=180
connections
• A topology is allocated with three workers
Let's assume when we submit this topology onto the cluster, the tasks and processes are
spawned as shown in the following screenshot:
The preceding figure depicts the cluster diagrammatically and the gray workers are the
ones that are allocated to the topology. Now we are all set to try out the high availability
test for Storm and Zookeeper. The tests for Storm and Zookeeper are as follows:
Test 1 (all components are up and the topology is running): Kill the Nimbus node
after the topology is submitted; you will notice that the topology will continue to
execute normally.
Test 2 (all components are up and the topology is running): Kill one Zookeeper
node and you will notice that the topology will continue to execute normally, be-
Search WWH ::




Custom Search