doc-exports/docs/dws/dev/dws_04_0933.html
Lu, Huayi e6fa411af0 DWS DEV 830.201 version
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: Lu, Huayi <luhuayi@huawei.com>
Co-committed-by: Lu, Huayi <luhuayi@huawei.com>
2024-05-16 07:24:04 +00:00

50 lines
9.9 KiB
HTML

<a name="EN-US_TOPIC_0000001188482176"></a><a name="EN-US_TOPIC_0000001188482176"></a>
<h1 class="topictitle1">Connection Pool Parameters</h1>
<div id="body8662426"><p id="EN-US_TOPIC_0000001188482176__a1cadae29bdd84e19ac3b9bae49d0759f">When a connection pool is used to access the database, database connections are established and then stored in the memory as objects during system running. When you need to access the database, no new connection is established. Instead, an existing idle connection is selected from the connection pool. After you finish accessing the database, the database does not disable the connection but puts it back into the connection pool. The connection can be used for the next access request.</p>
<div class="section" id="EN-US_TOPIC_0000001188482176__s15eadd0e20bd4216a410c365691bf004"><h4 class="sectiontitle">min_pool_size</h4><p id="EN-US_TOPIC_0000001188482176__aed91a7de77354e05a017b744eacc6d4b"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_en-us_topic_0058967595_b384857591194">Parameter description</strong>: Specifies the minimum number of connections between a CN's connection pool and another CN/DN.</p>
<p id="EN-US_TOPIC_0000001188482176__p202725159174"><strong id="EN-US_TOPIC_0000001188482176__b631872012286">Type</strong>: POSTMASTER</p>
<p id="EN-US_TOPIC_0000001188482176__a80e3618ee551489e8f9fc829ccc94961"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_a8c445e03d3604f8099ed6eefb3478489">Value range</strong>: an integer ranging from 1 to 65535</p>
<p id="EN-US_TOPIC_0000001188482176__a0804b166a0a24b6c8707916bfb5e9185"><strong id="EN-US_TOPIC_0000001188482176__a4c25757a8859417e8d363ca9016b506c">Default value</strong>: <strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0058967566_b56157513619462">1</strong></p>
</div>
<div class="section" id="EN-US_TOPIC_0000001188482176__sc9c97fb885594225a376d39f91845fee"><h4 class="sectiontitle">max_pool_size</h4><p id="EN-US_TOPIC_0000001188482176__a3b121f3339d3491b80ee2aa00f66992e"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_a1ca253ddce2441cf8b8d6f82d17c7f9e">Parameter description</strong>: Specifies the maximum number of connections between a CN's connection pool and another CN/DN.</p>
<p id="EN-US_TOPIC_0000001188482176__p1885114228172"><strong id="EN-US_TOPIC_0000001188482176__b382382015282">Type</strong>: POSTMASTER</p>
<p id="EN-US_TOPIC_0000001188482176__a986b627362984189a31ab73966eb2898"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_ada726e79b9c74f56ba3626fe5f5b1677">Value range</strong>: an integer ranging from 1 to 65535</p>
<p id="EN-US_TOPIC_0000001188482176__af243e3971ca441089644847a6aee996f"><strong id="EN-US_TOPIC_0000001188482176__b1967920595297">Default value</strong>: <strong id="EN-US_TOPIC_0000001188482176__b1068555912299">800</strong> for CNs and <strong id="EN-US_TOPIC_0000001188482176__b868525915297">5000</strong> for DNs</p>
</div>
<div class="section" id="EN-US_TOPIC_0000001188482176__s54b4d54e64cf428a9252ba49d1cdd764"><h4 class="sectiontitle">persistent_datanode_connections</h4><p id="EN-US_TOPIC_0000001188482176__a738cbfaa6cb54465baa34876da91e104"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_ad21f6468a3c6461996f0aab15ae85e27">Parameter description</strong>: Specifies whether to release the connection for the current session.</p>
<p id="EN-US_TOPIC_0000001188482176__p3484113092116"><strong id="EN-US_TOPIC_0000001188482176__b35453211280">Type</strong>: USERSET</p>
<p id="EN-US_TOPIC_0000001188482176__a0a6616daa1be461395783884efb042d4"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_a5ec3a68435cc432eaa6db4762412b487">Value range</strong>: Boolean</p>
<ul id="EN-US_TOPIC_0000001188482176__u2cd2d2836d4c49d8a7a64fdf1722fa3c"><li id="EN-US_TOPIC_0000001188482176__l57ee25a767f94ab8b9f7331d9bb93b42"><strong id="EN-US_TOPIC_0000001188482176__b8423527061141">off</strong> indicates that the connection for the current session will be released.</li><li id="EN-US_TOPIC_0000001188482176__l4e85a05db83545b0a04a8c11c1029bf1"><strong id="EN-US_TOPIC_0000001188482176__b84235270611425">on</strong> indicates that the connection for the current session will not be released.<div class="notice" id="EN-US_TOPIC_0000001188482176__naf35617accbd4929904bc019b87774ec"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="EN-US_TOPIC_0000001188482176__af187cf68aade4c78bb7f8b8d8152c7e6">After this function is enabled, a session may hold a connection but does not run a query. As a result, other query requests fail to be connected. To fix this problem, the number of sessions must be less than or equal to <strong id="EN-US_TOPIC_0000001188482176__b84235270616156">max_active_statements</strong>.</p>
</div></div>
</li></ul>
<p id="EN-US_TOPIC_0000001188482176__ae4423ac5b2604a1587cb37f47148c777"><strong id="EN-US_TOPIC_0000001188482176__b55233292105553">Default value</strong>: <strong id="EN-US_TOPIC_0000001188482176__b842352706172155">off</strong></p>
</div>
<div class="section" id="EN-US_TOPIC_0000001188482176__se03ee3f924314e70b9a42e77ef722221"><h4 class="sectiontitle">cache_connection</h4><p id="EN-US_TOPIC_0000001188482176__aba07f9d3fe5e4d4e913daf534b825849"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_aff31e1628fc84fc88d7d478bcc5a657f">Parameter description</strong>: Specifies whether to reclaim the connections of a connection pool.</p>
<p id="EN-US_TOPIC_0000001188482176__p1486312190189"><strong id="EN-US_TOPIC_0000001188482176__b15970132432820">Type</strong>: SIGHUP</p>
<p id="EN-US_TOPIC_0000001188482176__aec932c9fb0054788987d117a372b5abe"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_aeececbe0666644ef9dae29b4d7cbb3fe">Value range</strong>: Boolean</p>
<ul id="EN-US_TOPIC_0000001188482176__ue0e25b0236b845f6aec7ca32ac3d059f"><li id="EN-US_TOPIC_0000001188482176__l513e16ab830448ab8a463f1b81fbd22c"><strong id="EN-US_TOPIC_0000001188482176__b84235270611753">on</strong> indicates that the connections of a connection pool will be reclaimed.</li><li id="EN-US_TOPIC_0000001188482176__l647543f14ba94cabb816c7be6c37b1de"><strong id="EN-US_TOPIC_0000001188482176__b1865663302">off</strong> indicates that the connections of a connection pool will not be reclaimed.</li></ul>
<p id="EN-US_TOPIC_0000001188482176__a6dce22e3e6ac48a2b760790759faf143"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778346_a30e99140fb09438ab2bb77f75bd21bb4">Default value</strong>: <strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778346_en-us_topic_0058967649_b842352706195040">on</strong></p>
</div>
<div class="section" id="EN-US_TOPIC_0000001188482176__section201924413346"><h4 class="sectiontitle">enable_force_reuse_connections <strong id="EN-US_TOPIC_0000001188482176__b419219483419"></strong></h4><p id="EN-US_TOPIC_0000001188482176__p94501445375"><strong id="EN-US_TOPIC_0000001188482176__b19777112310596">Parameter description</strong>: Specifies whether a session forcibly reuses a new connection.</p>
<p id="EN-US_TOPIC_0000001188482176__p6945105582016"><strong id="EN-US_TOPIC_0000001188482176__b1059172542813">Type</strong>: BACKEND</p>
<p id="EN-US_TOPIC_0000001188482176__p845074415371"><strong id="EN-US_TOPIC_0000001188482176__b1494045465813">Value range</strong>: Boolean</p>
<ul id="EN-US_TOPIC_0000001188482176__ul19450144493715"><li id="EN-US_TOPIC_0000001188482176__li1345014443719"><strong id="EN-US_TOPIC_0000001188482176__b676725912591">on</strong> indicates that the new connection is forcibly used.</li><li id="EN-US_TOPIC_0000001188482176__li14960351175814"><strong id="EN-US_TOPIC_0000001188482176__b202226187016">off</strong> indicates that the current connection is used.</li></ul>
<p id="EN-US_TOPIC_0000001188482176__p1567854435615"><strong id="EN-US_TOPIC_0000001188482176__b17265194125912">Default value</strong>: <strong id="EN-US_TOPIC_0000001188482176__b4266164115918">off</strong></p>
<div class="note" id="EN-US_TOPIC_0000001188482176__note13188242405"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001188482176__p1158022720401">This is a session connection parameter. You are advised not to configure this parameter.</p>
</div></div>
</div>
<div class="section" id="EN-US_TOPIC_0000001188482176__sab7f9d112d1d489e874a2e2d511278e6"><h4 class="sectiontitle">enable_pooler_parallel <strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_b967840510223"></strong></h4><p id="EN-US_TOPIC_0000001188482176__a27f57ee837a14e47b1bdfd8aae549343"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_b6225159310216">Parameter description</strong>: Specifies whether a CN's connection pool can be connected in parallel mode.</p>
<p id="EN-US_TOPIC_0000001188482176__p2964143714209"><strong id="EN-US_TOPIC_0000001188482176__b38621626192816">Type</strong>: SIGHUP</p>
<p id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_p815681710216"><strong id="EN-US_TOPIC_0000001188482176__en-us_topic_0059778940_b630248910216">Value range</strong>: Boolean</p>
<ul id="EN-US_TOPIC_0000001188482176__ua1e5ddc3bec44392b888c693fd1f7266"><li id="EN-US_TOPIC_0000001188482176__ld4836b5a92334c0e9bb0a9ebc13dfee1"><strong id="EN-US_TOPIC_0000001188482176__b842352706153954">on</strong> indicates that a CN's connection pool can be connected in parallel mode.</li><li id="EN-US_TOPIC_0000001188482176__lf8c84f8422b34258944d47e17e29271b"><strong id="EN-US_TOPIC_0000001188482176__b149834833114385">off</strong> indicates that a CN's connection pool cannot be connected in parallel mode.</li></ul>
<p id="EN-US_TOPIC_0000001188482176__af0de62e1d7c14c2db01cb517029cd3cb"><strong id="EN-US_TOPIC_0000001188482176__b19573715114114">Default value</strong>: <strong id="EN-US_TOPIC_0000001188482176__b842352706172116">on</strong></p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="dws_04_0883.html">GUC Parameters</a></div>
</div>
</div>