HTTP persistent connection, also called HTTP keep-alive, or HTTP connection reuse, is the idea of using a single TCP connection to send and receive multiple HTTP requests/responses, as opposed to opening a new connection for every single request/response pair. The newer HTTP/2 protocol uses the same idea and takes it further to allow multiple concurrent requests/responses to be multiplexed over a single connection.
Questions tagged [persistent-connection]
153 questions
2
votes
2 answers
mysql.h persistent connection
Is it possible to get persistent connections with the MySQL C API, like those PHP provides? If so, how?
user1382306
2
votes
2 answers
Optimizing Jetty for heartbeat detection of thousands of machines?
I have a large number of machines (thousands and more) that every X seconds would perform an HTTP request to a Jetty server to notify they are alive. For what value of X should I use persistent HTTP connections (which limits number of monitored…

itaifrenkel
- 1,578
- 1
- 12
- 26
2
votes
1 answer
PHP: How to know if a PostgreSQL persistent connection is already opened?
According to PHP.net manual, pg_pconnect will create a persistent connection, or will return the existing one if it already exists with same connection string.
The problem I have is I want to know whether that call indeed creates a connection or…

StormByte
- 1,266
- 1
- 13
- 33
2
votes
1 answer
Persistent Connection to server with PHP infinite loop
I want to keep my website updated one new information is added in the database. I can't use Node.js and Comet Programming, and Javascript's setInterval seems to be a bad idea because of too many requests.
Now I am using something like this …

John
- 7,500
- 16
- 62
- 95
2
votes
2 answers
Does "mysqli::close" close persistent connections?
PHP doc says "mysql_close() will not close persistent links".
Is it the same with mysqli (mysqli::close()) ?

lacorbeille
- 325
- 1
- 4
- 8
2
votes
1 answer
persistent connection in xpages and domino
When I login to an xpage application from a browser the connection drop is done at 5 minutes, whereas when I access a traditional domino application the connection drop is around 1 minute. I am using session based authentication on a single server…

user1186272
- 97
- 2
- 7
2
votes
4 answers
How to design a server with many persistent connections
I am designing a application where many clients connect to a central server. This server keeps these connections, sending keep-alives every half-hour. The server has a embedded HTTP server, which provides a interface to the client connections (ex.…

Isaac Waller
- 32,709
- 29
- 96
- 107
1
vote
1 answer
Java Server - TCP Socket detect EOF without closing the socket connection
Is there a way to detect the EOF when reading from a TCP Socket whilst the socket connection stays open?
Most of the examples I have seen are something along the lines of:
int n=0;
While((n = read.inStream(data)) != -1){
destType.write(data, 0,…

Jay
- 115
- 2
- 7
1
vote
1 answer
osCommerce: Use persistent connection
I have here a osCommerce 2.2-MS2. I had some settings before which were working fine. Now I changed the settings for the connection to the database (username, password, database, ...) but didn't noticed that the changes weren't saved. Now I want to…

testing
- 19,681
- 50
- 236
- 417
1
vote
0 answers
Windows Server 2016 mount shared folder as disc permanently also on restart
I'm have local access to a shared folder with credentials.
net use Z: \\server\folder /u:user /persistent:yes passwd
The files in this folder are to be used by other processes.
The problem is that when the machine is restarted, the connection is…

Ahadu Tsegaye Abebe
- 685
- 6
- 18
1
vote
0 answers
Jetty embedded with different behavior for persistent connection on two Linux systems
I am testing a Jetty embedded server (similar to jersey-http2-jetty-bundle) called by a Jersey HTTP/1.1 (HttpURLConnection) client on two different servers.
Linux amss1 4.9.125-linuxkit #1 SMP Fri Sep 7 08:20:28 UTC 2018 x86_64 GNU/Linux
Linux…

Nicolas Henneaux
- 11,507
- 11
- 57
- 82
1
vote
1 answer
php mysqli persistent connection not being shared in App Engine
We have an application written in php using mysqli running on Google App Engine and connecting to Google Cloud SQL. We have a file connection.php that instantiate
$connection = new mysqli(...);
and this script is included in all the scripts that…

andy
- 195
- 1
- 2
- 15
1
vote
0 answers
Mitigate HTTPS overhead with php microservices
We have a main webservice using several microservices.
The main service is called really often (lot of queries) and has been profiled and designed to be blazing fast from code perspective.
If we had 5 microservices behind the main webservice, for…

nemenems
- 1,064
- 2
- 9
- 27
1
vote
4 answers
persistent php connection?
Is it possible to have a php script pause at a certain point wait for an ajax response, then continue executing?
If not, what is the most appropriate way to store the current state of a script (all defined variables ect) untill it in invoked again?

Hailwood
- 89,623
- 107
- 270
- 423
1
vote
1 answer
every request from a django app increasing mysql number of connections
I have a project built using django 1.11 and i am sending a request from my admin view and it is creating a new DB connection on every request(using django development server, runserver).
But the same thing using gunicorn as server does not increase…

mukul
- 111
- 8