[PoC9] Performant setup w/ Cassandra, Netty, NGINX, RESTEasy to handle REST web service requests

Mert Çalışkan
2 min readAug 5, 2015

--

After a series of PoCs (this, that and many others) executed on Amazon EC2, now it’s time to build up the stack that I’m planning to use for production. The setup goes like this:

So there are 5 instances for creating the Cassandra cluster, 2 instances to host my custom REST web service implementation, 1 instance for the NGINX to load balance the requests and 1 instance for the requester client. You can find the custom implementations from given links: http-requester and cassandra-netty-rest-simple.

Cassandra nodes are installed and configured having the commit log stored in a separate disk drive. NGINX installation is configured by editing the /etc/sysctl.conf file and adding net.ipv4.tcp_tw_reuse key with value 1.

So http-requester creates requests and sends them to NGINX. NGINX load-balances them onto 2 servers that contains the REST web service impl. REST web services interacts with Cassandra cluster and store an object for each request. For this scenario the request/sec graph was as follows:

For a total 6 minutes PoC handled 16.680.508 requests with an average of 46334 requests/sec.

--

--

Mert Çalışkan

Opsgenie Champion at Atlassian. Oracle Java Champion. AnkaraJUG Lead. Author of Beginning Spring & PrimeFaces Cookbook.