- 3,723,925 Users
- 2,244,650 Discussions
- 7,850,759 Comments
Forum Stats
Discussions
Categories
- 16 Data
- 362.2K Big Data Appliance
- 7 Data Science
- 2.1K Databases
- 618 General Database Discussions
- 3.7K Java and JavaScript in the Database
- 32 Multilingual Engine
- 497 MySQL Community Space
- 7 NoSQL Database
- 7.7K Oracle Database Express Edition (XE)
- 2.8K ORDS, SODA & JSON in the Database
- 422 SQLcl
- 62 SQL Developer Data Modeler
- 185.1K SQL & PL/SQL
- 21.1K SQL Developer
- 2.4K Development
- 3 Developer Projects
- 32 Programming Languages
- 135.6K Development Tools
- 14 DevOps
- 3K QA/Testing
- 337 Java
- 10 Java Learning Subscription
- 12 Database Connectivity
- 72 Java Community Process
- 2 Java 25
- 12 Java APIs
- 141.2K Java Development Tools
- 8 Java EE (Java Enterprise Edition)
- 153K Java Essentials
- 135 Java 8 Questions
- 86.2K Java Programming
- 270 Java Lambda MOOC
- 65.1K New To Java
- 1.7K Training / Learning / Certification
- 13.8K Java HotSpot Virtual Machine
- 16 Java SE
- 13.8K Java Security
- 4 Java User Groups
- 22 JavaScript - Nashorn
- 18 Programs
- 147 LiveLabs
- 34 Workshops
- 10 Software
- 4 Berkeley DB Family
- 3.5K JHeadstart
- 5.7K Other Languages
- 2.3K Chinese
- 4 Deutsche Oracle Community
- 16 Español
- 1.9K Japanese
- 3 Portuguese
Connection String. Idle Timeout, Command Timeout,

Hi!
Let's compare oracle and npgsql settings
See https://www.npgsql.org/doc/connection-string-parameters.html
1.
<strong>Connection Lifetime vs Connection Idle Lifetime</strong><br/><br/>
Connection Lifetime (oracle)<br/>
Maximum life time (in seconds) of the connection.
Connection Idle Lifetime (npgsql)
The time (in seconds) to wait before closing idle connections in the pool if the count of all connections exceeds Minimum Pool Size
. Since 3.1 only.
In the case of npgsql, it is clear what and why.
There is a similar parameter in oracle, but it doesn’t work like that, you need a game with the pool regulator setting in order to add a similar result.
2. Command Timeout
In oracle, there is no such parameter in the connection string, only the class has it.
BUT, if you look at the library code, then it’s clear that this setting creates a timer that dies after a certain step of command execution and there’s little sense in it.
<br/><br/>
Answers
-
You'll see the Connection Lifetime attribute more fully described in the API reference section:
CommandTimeout is on the OracleCommand object since developers may want to modify the setting over the lifetime of the connection. If the command timeout is on the connection, it must remain the same throughout the connection's lifetime. Moreover, modifying the command timeout creates a new connection pool in the PostgreSQL model. When you modify the CommandTimeout in ODP.NET, no new pool is required. The same pool can be used.