Преглед изворни кода

Clarified database connections lifetime outside HTTP requests.

Alberto Sottile пре 1 година
родитељ
комит
e901407e23
1 измењених фајлова са 5 додато и 1 уклоњено
  1. 5 1
      docs/ref/databases.txt

+ 5 - 1
docs/ref/databases.txt

@@ -31,7 +31,7 @@ Persistent connections
 ----------------------
 
 Persistent connections avoid the overhead of reestablishing a connection to
-the database in each request. They're controlled by the
+the database in each HTTP request. They're controlled by the
 :setting:`CONN_MAX_AGE` parameter which defines the maximum lifetime of a
 connection. It can be set independently for each database.
 
@@ -97,6 +97,10 @@ either restore Django's defaults at the end of each request, force an
 appropriate value at the beginning of each request, or disable persistent
 connections.
 
+If a connection is created in a long-running process, outside of Django’s
+request-response cycle, the connection will remain open until explicitly
+closed, or timeout occurs.
+
 Encoding
 --------