nats scalability questions

345 views
Skip to first unread message

Adam Dyga

unread,
Jul 9, 2015, 6:26:41 AM7/9/15
to nat...@googlegroups.com

Hello All,

I would like to ask some questions about nats scalability:

1. What are practical limits of nats (both in terms of broker cluster size and number concurrent of clients)? What is the biggest known nats cluster used in production?
2. Is it possible to scale out/scale down dynamically at runtime (eg. add/remove brokers to the clusters with no downtime)?

Regards,
Adam

Derek Collison

unread,
Jul 9, 2015, 12:00:28 PM7/9/15
to nat...@googlegroups.com
NATS has resource usage around 100k on a per connection basis for optimal performance. That being said, and individual broker is really only limited by memory. Not sure about others, but I have run a single gnatsd with > 50k connections. I do have a planned work items to introduce a dynamic buffer system to reduce the per connection footprint.

In terms of cluster size, NATS (gnatsd) uses a fully connected one-hop mesh topology. I think 2,3 or 5 are good sizes. Right now these have to all be configured. There is a planned TODO to add in a gossip protocol which could have any new server simply point to a seed server. Propagation of servers to others and to clients will be automatic when this work is done. For now, you need to add in the new server to the cluster and make the clients aware of it.

For example. Say you have one server, server A. When you start B, you simply need to make sure B points to A. When you start C, you will need C to point to A and B. Update the client configurations accordingly.

Hope that helps.
Reply all
Reply to author
Forward
0 new messages