You can use connection properties to customize the driver for your environment. This section organizes connection properties according to functionality. You can use connection properties with either the JDBC DriverManager or a JDBC data source. For a DriverManager connection, a property is expressed as a key value pair and takes the form property=value. For a data source connection, a property is expressed as a JDBC method and takes the form setproperty(value).

Note:
  • In a JDBC data source, string values must be enclosed in double quotation marks, for example, setUser("abc@defcorp.com").
  • The data type listed for each connection property is the Java data type used for the property value in a JDBC data source.
  • Connection property names are case-insensitive. For example, Password is the same as password.
  • For connection properties that support string values, use the following escape sequence to specify values containing leading or trailing spaces and curly brackets: {value}. For example: User={hello } or Password={{hello}}.

The following tables describe the connection properties by functionality:

Basic connection properties

The following table summarizes connection properties which are required to connect to a MongoDB data source.

Table 1. Basic Properties
Property Data Source Method Default
DatabaseName

getDatabaseName()

setDatabaseName(String)

No default value
PortNumber

getPortNumber()

setPortNumber(Integer)

27107
ServerName

getServerName()

setServerName(String)

No default value

User ID and password authentication connection properties

The following table summarizes connection properties used for user ID and password authentication.

Table 2. User ID and password authentication properties
Property Data Source Method Default
AuthenticationDatabase

getAuthenticationDatabase()

setAuthenticationDatabase(String)

No default value

AuthenticationMethod getAuthenticationMethod()

setAuthenticationMethod(String)

UserIDPassword
Password getPassword()

setPassword(String)

No default value
User getUser()

setUser(String)

No default value

Kerberos authentication properties

The following table summarizes connection properties used for Kerberos authentication.

Table 3. URL parameter authentication properties
Property Data Source Method Default
AuthenticationMethod getAuthenticationMethod()

setAuthenticationMethod(String)

UserIDPassword

ServicePrincipalName

getServicePrincipalName()

setServicePrincipalName(String)

No default value
User getUser()

setUser(String)

No default value

LDAP authentication properties

The following table summarizes connection properties used for LDAP authentication.

Table 4. URL parameter authentication properties
Property Data Source Method Default
AuthenticationMethod getAuthenticationMethod()

setAuthenticationMethod(String)

UserIDPassword

Password getPassword()

setPassword(String)

No default value
User getUser()

setUser(String)

No default value

TLS/SSL encryption properties

The following table summarizes properties used for configuring TLS/SSL encryption.

Table 5. Data encryption properties
Property Data Source Method Default
CryptoProtocolVersion

getCryptoProtocolVersion()

setCryptoProtocolVersion(String)

No default value
EncryptionMethod

getEncryptionMethod()

setEncryptionMethod(String)

NoEncryption
HostNameInCertificate

getHostNameInCertificate()

setHostNameInCertificate(String)

No default value
KeyPassword

getKeyPassword()

setKeyPassword(String)

No default value
Keystore

getKeystore()

setKeystore(String)

No default value
KeystorePassword

getKeystorePassword()

setKeystorePassword(String)

No default value
Truststore

getTruststore()

setTruststore(String)

No default value
TruststorePassword

getTruststorePassword()

setTruststorePassword(String)

No default value
ValidateServerCertificate

getValidateServerCert()

setValidateServerCert(Boolean)

No default value

Mapping properties

The following table summarizes connection properties involved in mapping the MongoDB data model to a SQL model.

Table 6. Mapping properties
Property Data Source Method Default
ArrayNormalizationThreshold

getArrayNormThreshold()

setArrayNormThreshold(Integer)

12

CreateMap getCreateMap()

setCreateMap(String)

NotExist
ColumnDiscoverySampleSize

getColumnDiscoverySampleSize()

setColumnDiscoverySampleSize(Integer)

1000
FlattenArrayBase

getFlattenArrayBase()

setFlattenArrayBase(Integer)

1

JSONColumns

getJsonColumns()

setJsonColumns(Boolean)

false
KeywordConflictSuffix

getKeywordConflictSuffix()

setKeywordConflictSuffix(String)

No default value
LeadingUnderscoreReplacement

getLeadingUnderscoreReplacement()

setLeadingUnderscoreReplacement(String)

None. When no value is specified, a leading underscore is used in identifiers.

LegacyVirtualKeys

getLegacyVirtualKeys()

setLegacyVirtualKeys(Boolean)

false
QualifyNormalizedNames

getQualifyNormalizedNames()

setQualifyNormalizedNames(String)

No
RefreshSchema

getRefreshSchema()

setRefreshSchema(Boolean)

false
SchemaFormat

getSchemaFormat()

setSchemaFormat(String)

Mixed
SchemaMap getSchemaMap()

setSchemaMap(String)

Default value depends on environment
SpecialCharBehavior

getSpecialCharBehavior()

setSpecialCharBehavior(String)

Include
UppercaseIdentifiers

getUpperCaseIdentifiers()

setUpperCaseIdentifiers(Boolean)

true

Proxy server properties

The following table summarizes proxy server connection properties.

Table 7. Proxy Server Properties
Property Data Source Method Default
ProxyHost

getProxyHost()

setProxyHost(String)

No default value

ProxyPassword

getProxyPassword()

setProxyPassword(String)

No default value
ProxyPort

getProxyPort()

setProxyPort(Integer)

0 which means that the default value is determined by the ServerName property.

For HTTP URLs: 80

For HTTPS URLs: 443

ProxyUser

getProxyUser()

setProxyUser(String)

No default value

Timeout properties

The following table summarizes timeout connection properties.

Table 8. Timeout Properties
Property Data Source Method Default
LoginTimeout getLoginTimeout()

setLoginTimeout(Integer)

0 (no timeout)

Statement pooling properties

The following table summarizes statement pooling connection properties.

Table 9. Statement Pooling Properties
Property Data Source Method Default
ImportStatementPool getImportStatementPool()

setImportStatementPool(String)

No default value
MaxPooledStatements getMaxPooledStatements()

setMaxPooledStatements(Integer)

0
RegisterStatementPoolMonitorMBean getRegisterStatementPoolMonitorMbean()

setRegisterStatementPoolMonitorMbean(Boolean)

false

Additional properties

The following table summarizes additional connection properties.

Table 10. Additional Properties
Property Data Source Method Default
EnableDNSLookup

getEnableDnsLookup()

setEnableDnsLookup(Boolean)

true
FetchSize getFetchSize()

setFetchSize(Integer)

100 (rows)
InitializationString getInitializationString()

setInitializationString(String)

No default value
LogConfigFile

getLogConfigFile()

setLogConfigFile(String)

ddlogging.properties
LoginConfigName

getLoginConfigName()

setLoginConfigName(String)

JDBC_DRIVER_01
MinVarcharSize

public Integer getMinVarcharSize()

public void setMinVarcharSize(Integer)

1
NetworkMessageCompressors

getNetworkMessageCompressors()

setNetworkMessageCompressors(String)

none
ReadOnly

getReadOnly()

setReadOnly(Boolean)

false
ReadPreference

getReadPreference()

setReadPreference(String)

Primary
ReplicaSetName

getReplicaSetName()

setReplicaSetName(String)

No default value

ResultMemorySize

getResultMemorySize()

setResultMemorySize(Integer)

-1
SpyAttributes getSpyAttributes()

setSpyAttributes(String)

No default value
SchemaFilter

getSchemaFilter()

setSchemaFilter(String)

No default value
StringTruncationMethodForWrites

getStringTruncationMethodForWrites()

setStringTruncationMethodForWrites(String)

Error
TimestampFormat

getTimestampFormat()

setTimestampFormat(String)

bigint
TransactionMode

getTransactionMode()

setTransactionMode(String)

NoTransactions
VarcharThreshold

getVarcharThreshold()

setVarcharThreshold(Integer)

4000 (characters)