What does concurrent connection mean?

10,163

Solution 1

"Concurrent connection" means the maximum number of TCP connections your server can handle at any one time. At any given time many TCP/IP requests are coming to your server. For instance a single, simple web page might require 10 connections.

  • 1 for the HTML page
  • 2 for included JS scripts
  • 7 for JPEG and PNG image files

If 5 people request this page at the same time it could result in 50 concurrent connections.

Solution 2

To add to SushiGuy's answer:

A connection is made whenever a client (i.e. a browser or a mobile app) requests a resource from a server (i.e. a web page, CSS, JS, image, etc).

From a servers point of view "concurrent connections" is the count of the number of clients that are connected at the same time.

In a traditional web page request, your browser will open a connection to the server, request and receive the HTML, close the connection, parse the html and then request the JS, CSS and Images. Browsers are typically able to open multiple connections to a server and request these resources in parallel, and then close those connections. Most are able to reuse a connection to request additional resources, but once all resources are downloaded the connections are closed. These connections are typically only open for a few seconds at most.

Web sockets impact this because they create a persistent connection between the client and the server while the client is running. So if you have 100 users running your app, they will all have at least one connection to your server open. If your server only supports 100 concurrent connections then you won't be able serve any other users, including serving the initial HTML.

Share:
10,163

Related videos on Youtube

rook99
Author by

rook99

Updated on September 18, 2022

Comments

  • rook99
    rook99 over 1 year

    While learning about what websockets are and how they work, I find it hard to understand what they mean by "concurrent connection".

    Can anyone explain to me what "concurrent connection" means in a Blog web app as an example?

    • dan
      dan about 5 years
      Websocket and "concurrent connections" are two very different things: websocket is a protocol for providing full-duplex communication between a client and server over TCP. As SushiGuy covered, "concurrent connections" is a server specification or setting that limits the number of connections for all client connections at any single time.