Skip to content

Commit 448deb1

Browse files
(DOCS-12986): Add FAQ item for connection memory allocation (#1650)
* (DOCS-12986): Add FAQ item for connection memory allocation * move faq item * move faq item * fix numeric formatting * wording * updates per review * formatting * remove extra bullet * updates * wording * wording * tweak * wording * wording * wording * incorporate edit from Alek
1 parent ff4a73f commit 448deb1

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

source/administration/connection-pool-overview.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ cluster. The availability of connections to individual nodes within a
7474
sharded cluster affects latency. Operations must wait for a connection
7575
to be established.
7676

77+
.. _connection-pool-settings:
78+
7779
Connection Pool Configuration Settings
7880
--------------------------------------
7981

source/faq/storage.txt

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,33 @@ To what size should I set the WiredTiger internal cache?
7171

7272
.. include:: /includes/extracts/wt-configure-cache.rst
7373

74+
How much memory does MongoDB allocate per connection?
75+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
76+
77+
Each connection uses up to 1 megabyte of RAM.
78+
79+
To optimize memory use for connections, ensure that you:
80+
81+
- Monitor the number of open connections to your deployment. Too many
82+
open connections result in excessive use of RAM and reduce available
83+
memory for the :term:`working set`.
84+
85+
- Close :ref:`connection pools <connection-pool-overview>` when they are
86+
no longer needed. A connection pool is a cache of open, ready-to-use
87+
database connections maintained by the driver. Closing unneeded pools
88+
makes additional memory resources available.
89+
90+
- Manage the size of your connection pool. The :urioption:`maxPoolSize`
91+
connection string option specifies the maximum number of open
92+
connections in the pool. By default, you can have up to 100 open
93+
connections in the pool. Lowering the ``maxPoolSize`` reduces the
94+
maximum amount of RAM used for connections.
95+
96+
.. tip::
97+
98+
To configure your connection pool, see
99+
:ref:`connection-pool-settings`.
100+
74101
How frequently does WiredTiger write to disk?
75102
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
76103

0 commit comments

Comments
 (0)