gateways
, the gateway will create one outbound gateway connection for each gateway in its configuration. It will also gossip other gateways it knows or discovers. Fewer external gateways
mean less configuration. Yet, the ability to discover more gateways and gateway nodes depends on these servers running. This is similar to seed server in cluster. It is recommended to have all seed server of a cluster listed in the gateways
section.In the example above cluster A has configured gateway connections for B (solid lines). B has discovered gateway connections to A (dotted lines). Note that the number of outgoing connections always matches the number of gateways with the same name.
In this second example, again configured connections are shown with solid lines and discovered gateway connections are shown using dotted lines. Gateways A and C were both discovered via gossiping; B discovered A and A discovered C.
N(N-1)/2
where N is the number of nodes in the cluster. On gateway configurations, outbound connections are the summation of Ni(M-1)
where Ni is the number of nodes in a gateway i, and M is the total number of gateways. Inbound connections are the summation of U-Ni
where U is the sum of all gateway nodes in all gateways, and N is the number of nodes in a gateway i. It works out that both inbound and outbound connection counts are the same.