tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bob DeRemer <>
Subject attempting to achieve 100K concurrent websocket connections on Tomcat 7.0.48 NIO
Date Fri, 01 Nov 2013 22:00:01 GMT
I'm looking for some advice on what Tomcat NIO connector settings to use to support 100K concurrent
websocket connections.  Hopefully I  can reach this goal through a combination of Tomcat NIO
Connector settings, and Server 2008 R2 configuration [if needed].

We're scale testing our websocket application and looking to see how many concurrent websocket
connections we can get on a single Tomcat instance - with the goal being 100K.  I've provided
the test landscape details at the bottom - all VERY BIG EC2 instances over 10 GB network,
so memory, CPU and network do not appear to be the problem when monitoring.

The problem we are running into is that we can't seem to establish even 50K connections into
Tomcat.  At some point, we start getting connect failures, similar to the following:

Couldn't connect null
                at org.apache.tomcat.websocket.WsWebSocketContainer.processResponse(
                at org.apache.tomcat.websocket.WsWebSocketContainer.connectToServer(
Wrapped by: javax.websocket.DeploymentException: The HTTP request to initiate the WebSocket
connection failed
                at org.apache.tomcat.websocket.WsWebSocketContainer.connectToServer(

I'm hoping that someone may be able to advise what changes we might make to the following
Tomcat NIO connector setting that will allow upwards of 100K websocket connections:

<Connector port="80"
           redirectPort="8443" />


The test landscape is all Windows Server 2008 R2 boxes running in EC2 and the
Test Client environment:

Our test client is a multi-threaded java client that makes use of the JSR356 ClientEndpoint
functionality.  We're creating 40K+ websocket connections from a single test client machine.
 The test client is Server 2008 R2 and we have configured it to allow 50K ephemeral ports,
so we should be able to establish 40K+ outbound websocket connections.

Server environment:

*         EC2 instance (cc2.8xlarge) (60 GB, 10 GB network, 16 vCPUs)

*         Server 2008 R2

*         Tomcat 7.0.48 (trunk)

*         Java 1.7.0_45

Skype: bob.deremer.thingworx
O: 610.594.6200 x812
M: 717.881.3986

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message