@@ -6925,9 +6925,14 @@ version of the Oracle Client libraries.
6925
6925
If you are using Oracle Client 19c, the latest [ Easy Connect Plus] [ 151 ] syntax
6926
6926
allows the use of multiple hosts or ports, along with optional entries for the
6927
6927
wallet location, the distinguished name of the database server, and even lets
6928
- some network configuration options be set. This means that a
6929
- [ ` sqlnet.ora ` ] ( #tnsadmin ) file is not needed for some common connection
6930
- scenarios.
6928
+ some network configuration options be set. This means that
6929
+ [ ` tnsnames.ora ` ] ( #tnsadmin ) or [ ` sqlnet.ora ` ] ( #tnsadmin ) files are not needed
6930
+ for some further common connection scenarios. For example, if a firewall
6931
+ terminates idle connections every four minutes, you may decide it is more
6932
+ efficient to keep connections alive instead of having the overhead of
6933
+ recreation. Your connection string could be
6934
+ ` "mydbmachine.example.com/orclpdb1?expire_time=3" ` to send packets every three
6935
+ minutes with the [ ` SQLNET.EXPIRE_TIME ` ] [ 159 ] feature.
6931
6936
6932
6937
#### <a name =" embedtns " ></a > 14.2.2 Embedded Connect Descriptor Strings
6933
6938
@@ -7225,28 +7230,32 @@ on each connection.
7225
7230
If you increase the size of the pool, you must [ increase the number of
7226
7231
threads] ( #numberofthreads ) used by Node.js.
7227
7232
7228
- The growth characteristics of a connection pool are determined by the
7229
- Pool attributes [ ` poolIncrement ` ] ( #proppoolpoolincrement ) ,
7233
+ The growth characteristics of a connection pool are determined by the Pool
7234
+ attributes [ ` poolIncrement ` ] ( #proppoolpoolincrement ) ,
7230
7235
[ ` poolMax ` ] ( #proppoolpoolmax ) , [ ` poolMin ` ] ( #proppoolpoolmin ) and
7231
- [ ` poolTimeout ` ] ( #proppoolpooltimeout ) . Note that when External
7232
- Authentication is used, the pool behavior is different, see
7233
- [ External Authentication ] ( #extauth ) .
7236
+ [ ` poolTimeout ` ] ( #proppoolpooltimeout ) . Note that when [ external
7237
+ authentication ] ( #extauth ) or [ heterogeneous pools ] ( #connpoolproxy ) are used, the
7238
+ pool growth behavior is different .
7234
7239
7235
7240
Pool expansion happens when the following are all true: (i)
7236
- [ ` getConnection() ` ] ( #getconnectionpool ) is called and (ii) all the
7237
- currently established connections in the pool are "checked out" by
7238
- previous ` getConnection() ` calls and are in-use by the application,
7239
- and (iii) the number of those connections is less than the pool's
7240
- ` poolMax ` setting.
7241
-
7242
- The Oracle Real-World Performance Group's general recommendation for
7243
- client connection pools is for the pool to have a fixed sized. The
7244
- values of ` poolMin ` and ` poolMax ` should be the same (and
7245
- ` poolIncrement ` equal to zero), and the firewall, [ resource
7246
- manager] [ 101 ] or user profile [ ` IDLE_TIME ` ] [ 100 ] should not expire
7247
- idle sessions. This avoids connection storms which can decrease
7248
- throughput. See [ About Optimizing Real-World Performance with Static
7249
- Connection Pools] [ 23 ] , which contains details about sizing of pools.
7241
+ [ ` pool.getConnection() ` ] ( #getconnectionpool ) is called and (ii) all the
7242
+ currently established connections in the pool are "checked out" by previous
7243
+ ` pool.getConnection() ` calls and are in-use by the application, and (iii) the
7244
+ number of those connections is less than the pool's ` poolMax ` setting.
7245
+
7246
+ The Oracle Real-World Performance Group's general recommendation for client
7247
+ connection pools is to use a fixed sized. The values of ` poolMin ` and ` poolMax `
7248
+ should be the same (and ` poolIncrement ` equal to zero), and the firewall,
7249
+ [ resource manager] [ 101 ] or user profile [ ` IDLE_TIME ` ] [ 100 ] should not expire
7250
+ idle sessions. This avoids connection storms which can decrease throughput.
7251
+ See [ Guideline for Preventing Connection Storms: Use Static Pools] [ 23 ] , which
7252
+ contains details about sizing of pools. Having a fixed size will guarantee that
7253
+ the database can handle the upper pool size. For example, if a pool needs to
7254
+ grow but the database resources are limited, then you may see errors such as
7255
+ * ORA-28547* . With a fixed pool size, this class of error will occur when the
7256
+ pool is created, allowing you to change the size before users access the
7257
+ application. With a dynamically growing pool, the error may occur much later
7258
+ after the pool has been in use for some time.
7250
7259
7251
7260
The Pool attribute [ ` stmtCacheSize ` ] ( #propconnstmtcachesize ) can be
7252
7261
used to set the statement cache size used by connections in the pool,
@@ -8426,11 +8435,14 @@ terminating idle connections.
8426
8435
You can configure your OS network settings and Oracle Net (which
8427
8436
handles communication between node- oracledb and the database).
8428
8437
8429
- For Oracle Net configuration, a [` tnsnames.ora` ](#tnsnames) file can
8430
- be used to configure the database service settings such as for
8431
- failover using Oracle RAC or a standby database . A
8432
- [` ENABLE=BROKEN` ][36 ] option can be used to aid detection of a
8433
- terminated remote server.
8438
+ For Oracle Net configuration, a [` tnsnames.ora` ](#tnsnames) file can be used to
8439
+ configure the database service settings such as for failover using Oracle RAC or
8440
+ a standby database.
8441
+
8442
+ A [` SQLNET.EXPIRE_TIME` ][159 ] or [` ENABLE=BROKEN` ][36 ] option can be used to
8443
+ prevent firewalls from terminating connections . They can also aid detection of
8444
+ a terminated remote database server . With Oracle Client 19c , you can use
8445
+ ` EXPIRE_TIME` in the [Easy Connect Plus](#easyconnect) connection string.
8434
8446
8435
8447
A [` sqlnet.ora` ][136 ] file can be used to configure settings like
8436
8448
[` SQLNET.OUTBOUND_CONNECT_TIMEOUT` ][33 ], [` SQLNET.RECV_TIMEOUT` ][34 ]
@@ -13980,7 +13992,7 @@ can be asked at [AskTom][158].
13980
13992
[20]: http://docs.libuv.org/en/v1.x/threadpool.html
13981
13993
[21]: https://github.com/libuv/libuv
13982
13994
[22]: https://github.com/oracle/node-oracledb/issues/603#issuecomment-277017313
13983
- [23]: https://www.oracle.com/pls/topic/lookup?ctx=dblatest&id=GUID-BC09F045-5D80-4AF5-93F5-FEF0531E0E1D
13995
+ [23]: https://www.oracle.com/pls/topic/lookup?ctx=dblatest&id=GUID-7DFBA826-7CC0-4D16-B19C-31D168069B54
13984
13996
[24]: https://www.oracle.com/pls/topic/lookup?ctx=dblatest&id=GUID-015CA8C1-2386-4626-855D-CC546DDC1086
13985
13997
[25]: https://www.oracle.com/pls/topic/lookup?ctx=dblatest&id=GUID-661BB906-74D2-4C5D-9C7E-2798F76501B3
13986
13998
[26]: http://www.oracle.com/technetwork/topics/php/php-scalability-ha-twp-128842.pdf
@@ -14114,3 +14126,4 @@ can be asked at [AskTom][158].
14114
14126
[156]: http://yum.oracle.com/
14115
14127
[157]: https://livesql.oracle.com/
14116
14128
[158]: https://asktom.oracle.com/
14129
+ [159]: https://www.oracle.com/pls/topic/lookup?ctx=dblatest&id=GUID-1070805B-0703-457C-8D2E-4EEC26193E5F
0 commit comments