Connection Parameter Options
Connection Parameter Options
This section lists and describes the connection properties provided by jdbc.IRISDataSource (the InterSystems implementation of javax.sql.DataSource). Connection properties can be set by passing them to DriverManager (as described in “Using DriverManager to Connect”) or calling connection property accessors (see “Class IRISDataSource” for a complete list).
The following connection properties are supported:
Optional. Integer indicating Connection Security Level. Valid levels are 0, 1, 2, 3, or 10. Default = 0.
0 - Instance Authentication (Password)
1 - Kerberos (authentication only)
2 - Kerberos with Packet Integrity
3 - Kerberos with Encryption
10 - TLS
See IRISDataSource methods getConnectionSecurityLevel() and setConnectionSecurityLevel().
Optional. String specifying the SERVER IP address or host name.
Connection parameter host — IP address or Fully Qualified Domain Name (FQDN). For example, both 127.0.0.1 and localhost indicate the local machine.
See DataSource methods getServerName() and setServerName().
Optional. String containing current Key Recovery Password setting. Default = null. See IRISDataSource methods getKeyRecoveryPassword() and setKeyRecoveryPassword().
Required. String containing password. Default = null. See IRISDataSource methods getPassword() and setPassword()
Optional. Integer specifying the TCP/IP port number for the connection.
Connection parameter port— TCP port number on which the InterSystems IRIS SuperServer is listening. The default is 1972 (or the first available number higher than that if more than one instance of InterSystems IRIS is installed — see DefaultPort in the Parameter File Reference).
See DataSource methods getPortNumber() and setPortNumber().
Optional. String indicating Service Principal Name. Default = null. See IRISDataSource methods getServicePrincipalName() and setServicePrincipalName()
Optional. Integer indicating TCP/IP SO_RCVBUF value (ReceiveBufferSize). Default = 0 (use system default value).
Optional. Integer indicating TCP/IP SO_SNDBUF value (SendBufferSize). Default = 0 (use system default value).
Optional. String containing current TLS Configuration Name for this object. Default = null. See IRISDataSource methods getSSLConfigurationName() and setSSLConfigurationName().
Optional. Boolean indicating TCP/IP TCP_NODELAY flag (Nodelay). Default = true.
Connection parameter nodelay — sets the TCP_NODELAY option if connecting via a IRISDataSource object. Toggling this flag can affect the performance of the application. Valid values are true and false. If not set, it defaults to true.
See IRISDataSource methods getNodelay() and setNodelay()
Optional. A java.sql.Connection constant indicating Transaction Isolation Level. Valid values are TRANSACTION_READ_UNCOMMITTED or TRANSACTION_READ_COMMITTED. Default = null (use system default value TRANSACTION_READ_UNCOMMITTED).
See IRISDataSource methods getTransactionIsolationLevel() and setTransactionIsolationLevel()
Listing Connection Properties
Code similar to the following can be used to list the available properties for any compliant JDBC driver:
java.sql.Driver drv = java.sql.DriverManager.getDriver(url);
java.sql.Connection dbconnection = drv.connect(url, user, password);
java.sql.DatabaseMetaData meta = dbconnection.getMetaData();
System.out.println ("\n\n\nDriver Info: ==========================");
System.out.println (meta.getDriverName());
System.out.println ("release " + meta.getDriverVersion() + "\n");
java.util.Properties props = new Properties();
DriverPropertyInfo[] info = drv.getPropertyInfo(url,props);
for(int i = 0; i <info.length; i++) {
System.out.println ("\n" + info[i].name);
if (info[i].required) {System.out.print(" Required");}
else {System.out.print (" Optional");}
System.out.println (", default = " + info[i].value);
if (info[i].description != null)
System.out.println (" Description:" + info[i].description);
if (info[i].choices != null) {
System.out.println (" Valid values: ");
for(int j = 0; j < info[i].choices.length; j++)
System.out.println(" " + info[i].choices[j]);
}
}