Class ConnectionPropertiesImpl
- java.lang.Object
-
- org.apache.ignite.internal.jdbc.thin.ConnectionPropertiesImpl
-
- All Implemented Interfaces:
Serializable,ConnectionProperties
public class ConnectionPropertiesImpl extends Object implements ConnectionProperties, Serializable
Holds JDBC connection properties.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringPROP_PREFIXPrefix for property names.-
Fields inherited from interface org.apache.ignite.internal.jdbc.thin.ConnectionProperties
SSL_MODE_DISABLE, SSL_MODE_REQUIRE
-
-
Constructor Summary
Constructors Constructor Description ConnectionPropertiesImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringdisabledFeatures()Any JDBC features could be force disabled.voiddisabledFeatures(String features)HostAndPortRange[]getAddresses()intgetConnectionTimeout()Note: zero value means there is no limits.DriverPropertyInfo[]getDriverPropertyInfo()intgetPartitionAwarenessPartitionDistributionsCacheSize()intgetPartitionAwarenessSqlCacheSize()StringgetPassword()StringgetQueryEngine()IntegergetQueryTimeout()Note: zero value means there is no limits.StringgetSchema()intgetSocketReceiveBuffer()intgetSocketSendBuffer()StringgetSslCipherSuites()Gets cipher suites.StringgetSslClientCertificateKeyStorePassword()Gets key store password.StringgetSslClientCertificateKeyStoreType()Gets key store type used for context creation.StringgetSslClientCertificateKeyStoreUrl()Gets the key store URL.StringgetSslFactory()Gets the class name of the custom implementation of the Factory<SSLSocketFactory>.StringgetSslKeyAlgorithm()Gets algorithm that will be used to create a key manager.StringgetSslMode()Gets SSL connection mode.StringgetSslProtocol()Gets protocol for secure transport.StringgetSslTrustCertificateKeyStorePassword()Gets trust store password.StringgetSslTrustCertificateKeyStoreType()Gets trust store type.StringgetSslTrustCertificateKeyStoreUrl()Gets the trust store URL.TransactionConcurrencygetTransactionConcurrency()StringgetTransactionLabel()intgetTransactionTimeout()@Nullable IntegergetUpdateBatchSize()Note: Batch size of 1 prevents deadlock on update where keys sequence are different in several concurrent updates.StringgetUrl()StringgetUserAttributesFactory()Gets the class name of the custom implementation of the Factory<Map<String, String>>.StringgetUsername()voidinit(String url, Properties props)booleanisAutoCloseServerCursor()booleanisCollocated()@Nullable BooleanisDataPageScanEnabled()booleanisDistributedJoins()booleanisEnforceJoinOrder()booleanisKeepBinary()Get keep binary configuration flag.booleanisLazy()booleanisPartitionAwareness()booleanisReplicatedOnly()booleanisSkipReducerOnUpdate()booleanisSslTrustAll()Gets trust any server certificate flag.booleanisTcpNoDelay()voidsetAddresses(HostAndPortRange[] addrs)voidsetAutoCloseServerCursor(boolean val)voidsetCollocated(boolean val)voidsetConnectionTimeout(@Nullable Integer timeout)Note: zero value means there is no limits.voidsetDataPageScanEnabled(@Nullable Boolean dataPageScanEnabled)voidsetDistributedJoins(boolean val)voidsetEnforceJoinOrder(boolean val)voidsetKeepBinary(boolean keepBinary)Set totrueto keep binary objects in binary form.voidsetLazy(boolean val)voidsetPartitionAwareness(boolean partitionAwareness)voidsetPartitionAwarenessPartitionDistributionsCacheSize(int partitionAwarenessPartDistributionsCacheSize)Sets partition distributions cache size that is used within partition awareness optimizations.voidsetPartitionAwarenessSqlCacheSize(int partitionAwarenessSqlCacheSize)Sets SQL cache size that is used within partition awareness optimizations.voidsetPassword(String passwd)voidsetQueryEngine(String qryEngine)Sets SQL query engine for a connection.voidsetQueryTimeout(@Nullable Integer timeout)Note: zero value means there is no limits.voidsetReplicatedOnly(boolean val)voidsetSchema(String schema)voidsetSkipReducerOnUpdate(boolean val)voidsetSocketReceiveBuffer(int size)voidsetSocketSendBuffer(int size)voidsetSslCipherSuites(String sslCipherSuites)Override default cipher suites.voidsetSslClientCertificateKeyStorePassword(String passwd)Sets key store password.voidsetSslClientCertificateKeyStoreType(String ksType)Sets key store type used in context initialization.voidsetSslClientCertificateKeyStoreUrl(String url)Sets path to the key store file.voidsetSslFactory(String sslFactory)Sets the class name of the custom implementation of the Factory<SSLSocketFactory>.voidsetSslKeyAlgorithm(String keyAlgorithm)Sets key manager algorithm that will be used to create a key manager.voidsetSslMode(String mode)Use SSL connection to Ignite node.voidsetSslProtocol(String sslProtocol)Sets protocol for secure transport.voidsetSslTrustAll(boolean trustAll)Sets totrueto trust any server certificate (revoked, expired or self-signed SSL certificates).voidsetSslTrustCertificateKeyStorePassword(String passwd)Sets trust store password.voidsetSslTrustCertificateKeyStoreType(String ksType)Sets trust store type.voidsetSslTrustCertificateKeyStoreUrl(String url)Sets path to the trust store file.voidsetTcpNoDelay(boolean val)voidsetTransactionConcurrency(String transactionConcurrency)Sets transaction concurrency.voidsetTransactionLabel(String transactionLabel)Sets transaction label.voidsetTransactionTimeout(int transactionTimeout)Sets transaction timeout in milliseconds.voidsetUpdateBatchSize(@Nullable Integer updateBatchSize)Note: Set to 1 to prevent deadlock on update where keys sequence are different in several concurrent updates.voidsetUrl(String url)voidsetUserAttributesFactory(String cls)Sets the class name of the custom implementation of the Factory<Map<String, String>>.voidsetUsername(String name)PropertiesstoreToProperties()
-
-
-
Field Detail
-
PROP_PREFIX
public static final String PROP_PREFIX
Prefix for property names.- See Also:
- Constant Field Values
-
-
Method Detail
-
getSchema
public String getSchema()
- Specified by:
getSchemain interfaceConnectionProperties- Returns:
- Schema name of the connection.
-
setSchema
public void setSchema(String schema)
- Specified by:
setSchemain interfaceConnectionProperties- Parameters:
schema- Schema name of the connection.
-
getUrl
public String getUrl()
- Specified by:
getUrlin interfaceConnectionProperties- Returns:
- The URL of the connection.
-
setUrl
public void setUrl(String url) throws SQLException
- Specified by:
setUrlin interfaceConnectionProperties- Parameters:
url- The URL of the connection.- Throws:
SQLException- On invalid URL.
-
getAddresses
public HostAndPortRange[] getAddresses()
- Specified by:
getAddressesin interfaceConnectionProperties- Returns:
- Ignite nodes addresses.
-
setAddresses
public void setAddresses(HostAndPortRange[] addrs)
- Specified by:
setAddressesin interfaceConnectionProperties- Parameters:
addrs- Ignite nodes addresses.
-
isDistributedJoins
public boolean isDistributedJoins()
- Specified by:
isDistributedJoinsin interfaceConnectionProperties- Returns:
- Distributed joins flag.
-
setDistributedJoins
public void setDistributedJoins(boolean val)
- Specified by:
setDistributedJoinsin interfaceConnectionProperties- Parameters:
val- Distributed joins flag.
-
isEnforceJoinOrder
public boolean isEnforceJoinOrder()
- Specified by:
isEnforceJoinOrderin interfaceConnectionProperties- Returns:
- Enforce join order flag.
-
setEnforceJoinOrder
public void setEnforceJoinOrder(boolean val)
- Specified by:
setEnforceJoinOrderin interfaceConnectionProperties- Parameters:
val- Enforce join order flag.
-
isCollocated
public boolean isCollocated()
- Specified by:
isCollocatedin interfaceConnectionProperties- Returns:
- Collocated flag.
-
setCollocated
public void setCollocated(boolean val)
- Specified by:
setCollocatedin interfaceConnectionProperties- Parameters:
val- Collocated flag.
-
isReplicatedOnly
public boolean isReplicatedOnly()
- Specified by:
isReplicatedOnlyin interfaceConnectionProperties- Returns:
- Replicated only flag.
-
setReplicatedOnly
public void setReplicatedOnly(boolean val)
- Specified by:
setReplicatedOnlyin interfaceConnectionProperties- Parameters:
val- Replicated only flag.
-
isAutoCloseServerCursor
public boolean isAutoCloseServerCursor()
- Specified by:
isAutoCloseServerCursorin interfaceConnectionProperties- Returns:
- Auto close server cursors flag.
-
setAutoCloseServerCursor
public void setAutoCloseServerCursor(boolean val)
- Specified by:
setAutoCloseServerCursorin interfaceConnectionProperties- Parameters:
val- Auto close server cursors flag.
-
getSocketSendBuffer
public int getSocketSendBuffer()
- Specified by:
getSocketSendBufferin interfaceConnectionProperties- Returns:
- Socket send buffer size.
-
setSocketSendBuffer
public void setSocketSendBuffer(int size) throws SQLException- Specified by:
setSocketSendBufferin interfaceConnectionProperties- Parameters:
size- Socket send buffer size.- Throws:
SQLException- On error.
-
getSocketReceiveBuffer
public int getSocketReceiveBuffer()
- Specified by:
getSocketReceiveBufferin interfaceConnectionProperties- Returns:
- Socket receive buffer size.
-
setSocketReceiveBuffer
public void setSocketReceiveBuffer(int size) throws SQLException- Specified by:
setSocketReceiveBufferin interfaceConnectionProperties- Parameters:
size- Socket receive buffer size.- Throws:
SQLException- On error.
-
isTcpNoDelay
public boolean isTcpNoDelay()
- Specified by:
isTcpNoDelayin interfaceConnectionProperties- Returns:
- TCP no delay flag.
-
setTcpNoDelay
public void setTcpNoDelay(boolean val)
- Specified by:
setTcpNoDelayin interfaceConnectionProperties- Parameters:
val- TCP no delay flag.
-
isLazy
public boolean isLazy()
- Specified by:
isLazyin interfaceConnectionProperties- Returns:
- Lazy query execution flag.
-
setLazy
public void setLazy(boolean val)
- Specified by:
setLazyin interfaceConnectionProperties- Parameters:
val- Lazy query execution flag.
-
isSkipReducerOnUpdate
public boolean isSkipReducerOnUpdate()
- Specified by:
isSkipReducerOnUpdatein interfaceConnectionProperties- Returns:
- Skip reducer on update flag.
-
setSkipReducerOnUpdate
public void setSkipReducerOnUpdate(boolean val)
- Specified by:
setSkipReducerOnUpdatein interfaceConnectionProperties- Parameters:
val- Skip reducer on update flag.
-
getSslMode
public String getSslMode()
Gets SSL connection mode.- Specified by:
getSslModein interfaceConnectionProperties- Returns:
- Use SSL flag.
-
setSslMode
public void setSslMode(String mode)
Use SSL connection to Ignite node. In case set to"require"SSL context must be configured.ConnectionProperties.setSslClientCertificateKeyStoreUrl(java.lang.String)property and related properties must be set up or JSSE properties must be set up (seejavax.net.ssl.keyStoreand otherjavax.net.ssl.*properties) In case set to"disable"plain connection is used. Available modes:"disable", "require". Default value is"disable"- Specified by:
setSslModein interfaceConnectionProperties- Parameters:
mode- SSL mode.
-
getSslProtocol
public String getSslProtocol()
Gets protocol for secure transport.- Specified by:
getSslProtocolin interfaceConnectionProperties- Returns:
- SSL protocol name.
-
setSslProtocol
public void setSslProtocol(String sslProtocol)
Sets protocol for secure transport. If not specified, TLS protocol will be used. Protocols implementations supplied by JSEE: SSLv3 (SSL), TLSv1 (TLS), TLSv1.1, TLSv1.2See more at JSSE Reference Guide.
- Specified by:
setSslProtocolin interfaceConnectionProperties- Parameters:
sslProtocol- SSL protocol name.
-
getSslCipherSuites
public String getSslCipherSuites()
Gets cipher suites.- Specified by:
getSslCipherSuitesin interfaceConnectionProperties- Returns:
- SSL cipher suites.
-
setSslCipherSuites
public void setSslCipherSuites(String sslCipherSuites)
Override default cipher suites.See more at JSSE Reference Guide.
- Specified by:
setSslCipherSuitesin interfaceConnectionProperties- Parameters:
sslCipherSuites- SSL cipher suites.
-
getSslKeyAlgorithm
public String getSslKeyAlgorithm()
Gets algorithm that will be used to create a key manager.- Specified by:
getSslKeyAlgorithmin interfaceConnectionProperties- Returns:
- Key manager algorithm.
-
setSslKeyAlgorithm
public void setSslKeyAlgorithm(String keyAlgorithm)
Sets key manager algorithm that will be used to create a key manager. Notice that in most cased default value suites well, however, on Android platform this value need to be set to X509. Algorithms implementations supplied by JSEE: PKIX (X509 or SunPKIX), SunX509See more at JSSE Reference Guide.
- Specified by:
setSslKeyAlgorithmin interfaceConnectionProperties- Parameters:
keyAlgorithm- Key algorithm name.
-
getSslClientCertificateKeyStoreUrl
public String getSslClientCertificateKeyStoreUrl()
Gets the key store URL.- Specified by:
getSslClientCertificateKeyStoreUrlin interfaceConnectionProperties- Returns:
- Client certificate KeyStore URL.
-
setSslClientCertificateKeyStoreUrl
public void setSslClientCertificateKeyStoreUrl(String url)
Sets path to the key store file. This is a mandatory parameter since ssl context could not be initialized without key manager. In caseConnectionProperties.getSslMode()isrequiredand key store URL isn't specified by Ignite properties (e.g. at JDBC URL) the JSSE propertyjavax.net.ssl.keyStorewill be used.- Specified by:
setSslClientCertificateKeyStoreUrlin interfaceConnectionProperties- Parameters:
url- Client certificate KeyStore URL.
-
getSslClientCertificateKeyStorePassword
public String getSslClientCertificateKeyStorePassword()
Gets key store password.- Specified by:
getSslClientCertificateKeyStorePasswordin interfaceConnectionProperties- Returns:
- Client certificate KeyStore password.
-
setSslClientCertificateKeyStorePassword
public void setSslClientCertificateKeyStorePassword(String passwd)
Sets key store password. In caseConnectionProperties.getSslMode()isrequiredand key store password isn't specified by Ignite properties (e.g. at JDBC URL) the JSSE propertyjavax.net.ssl.keyStorePasswordwill be used.- Specified by:
setSslClientCertificateKeyStorePasswordin interfaceConnectionProperties- Parameters:
passwd- Client certificate KeyStore password.
-
getSslClientCertificateKeyStoreType
public String getSslClientCertificateKeyStoreType()
Gets key store type used for context creation.- Specified by:
getSslClientCertificateKeyStoreTypein interfaceConnectionProperties- Returns:
- Client certificate KeyStore type.
-
setSslClientCertificateKeyStoreType
public void setSslClientCertificateKeyStoreType(String ksType)
Sets key store type used in context initialization. In caseConnectionProperties.getSslMode()isrequiredand key store type isn't specified by Ignite properties (e.g. at JDBC URL)the JSSE propertyjavax.net.ssl.keyStoreTypewill be used. In case both Ignite properties and JSSE properties are not set the default 'JKS' type is used.See more at JSSE Reference Guide.
- Specified by:
setSslClientCertificateKeyStoreTypein interfaceConnectionProperties- Parameters:
ksType- Client certificate KeyStore type.
-
getSslTrustCertificateKeyStoreUrl
public String getSslTrustCertificateKeyStoreUrl()
Gets the trust store URL.- Specified by:
getSslTrustCertificateKeyStoreUrlin interfaceConnectionProperties- Returns:
- Trusted certificate KeyStore URL.
-
setSslTrustCertificateKeyStoreUrl
public void setSslTrustCertificateKeyStoreUrl(String url)
Sets path to the trust store file. This is an optional parameter, however one of thesetSslTrustCertificateKeyStoreUrl(String),ConnectionProperties.setSslTrustAll(boolean)properties must be set. In caseConnectionProperties.getSslMode()isrequiredand trust store URL isn't specified by Ignite properties (e.g. at JDBC URL) the JSSE propertyjavax.net.ssl.trustStorewill be used.- Specified by:
setSslTrustCertificateKeyStoreUrlin interfaceConnectionProperties- Parameters:
url- Trusted certificate KeyStore URL.
-
getSslTrustCertificateKeyStorePassword
public String getSslTrustCertificateKeyStorePassword()
Gets trust store password.- Specified by:
getSslTrustCertificateKeyStorePasswordin interfaceConnectionProperties- Returns:
- Trusted certificate KeyStore password.
-
setSslTrustCertificateKeyStorePassword
public void setSslTrustCertificateKeyStorePassword(String passwd)
Sets trust store password. In caseConnectionProperties.getSslMode()isrequiredand trust store password isn't specified by Ignite properties (e.g. at JDBC URL) the JSSE propertyjavax.net.ssl.trustStorePasswordwill be used.- Specified by:
setSslTrustCertificateKeyStorePasswordin interfaceConnectionProperties- Parameters:
passwd- Trusted certificate KeyStore password.
-
getSslTrustCertificateKeyStoreType
public String getSslTrustCertificateKeyStoreType()
Gets trust store type.- Specified by:
getSslTrustCertificateKeyStoreTypein interfaceConnectionProperties- Returns:
- Trusted certificate KeyStore type.
-
setSslTrustCertificateKeyStoreType
public void setSslTrustCertificateKeyStoreType(String ksType)
Sets trust store type. In caseConnectionProperties.getSslMode()isrequiredand trust store type isn't specified by Ignite properties (e.g. at JDBC URL) the JSSE propertyjavax.net.ssl.trustStoreTypewill be used. In case both Ignite properties and JSSE properties are not set the default 'JKS' type is used.- Specified by:
setSslTrustCertificateKeyStoreTypein interfaceConnectionProperties- Parameters:
ksType- Trusted certificate KeyStore type.
-
isSslTrustAll
public boolean isSslTrustAll()
Gets trust any server certificate flag.- Specified by:
isSslTrustAllin interfaceConnectionProperties- Returns:
- Trust all certificates flag.
-
setSslTrustAll
public void setSslTrustAll(boolean trustAll)
Sets totrueto trust any server certificate (revoked, expired or self-signed SSL certificates).Defaults is
false. Note: Do not enable this option in production you are ever going to use on a network you do not entirely trust. Especially anything going over the public internet.- Specified by:
setSslTrustAllin interfaceConnectionProperties- Parameters:
trustAll- Trust all certificates flag.
-
getSslFactory
public String getSslFactory()
Gets the class name of the custom implementation of the Factory<SSLSocketFactory>.- Specified by:
getSslFactoryin interfaceConnectionProperties- Returns:
- Custom class name that implements Factory<SSLSocketFactory>.
-
setSslFactory
public void setSslFactory(String sslFactory)
Sets the class name of the custom implementation of the Factory<SSLSocketFactory>. IfConnectionProperties.getSslMode()isrequiredand factory is specified the custom factory will be used instead of JSSE socket factory. So, other SSL properties will be ignored.- Specified by:
setSslFactoryin interfaceConnectionProperties- Parameters:
sslFactory- Custom class name that implements Factory<SSLSocketFactory>.
-
setUsername
public void setUsername(String name)
- Specified by:
setUsernamein interfaceConnectionProperties- Parameters:
name- User name to authentication.
-
getUsername
public String getUsername()
- Specified by:
getUsernamein interfaceConnectionProperties- Returns:
- User name to authentication.
-
setPassword
public void setPassword(String passwd)
- Specified by:
setPasswordin interfaceConnectionProperties- Parameters:
passwd- User's password.
-
getPassword
public String getPassword()
- Specified by:
getPasswordin interfaceConnectionProperties- Returns:
- User's password.
-
isDataPageScanEnabled
@Nullable public @Nullable Boolean isDataPageScanEnabled()
- Specified by:
isDataPageScanEnabledin interfaceConnectionProperties- Returns:
trueif data page scan support is enabled for this connection,falseif it's disabled andnullfor server default.
-
setDataPageScanEnabled
public void setDataPageScanEnabled(@Nullable @Nullable Boolean dataPageScanEnabled)- Specified by:
setDataPageScanEnabledin interfaceConnectionProperties- Parameters:
dataPageScanEnabled-trueif data page scan support is enabled for this connection, iffalsethen it's disabled, ifnullthen server should use its default settings.
-
isPartitionAwareness
public boolean isPartitionAwareness()
- Specified by:
isPartitionAwarenessin interfaceConnectionProperties- Returns:
trueif jdbc thin partition awareness is enabled for this connection,falseif it's disabled.
-
setPartitionAwareness
public void setPartitionAwareness(boolean partitionAwareness)
- Specified by:
setPartitionAwarenessin interfaceConnectionProperties- Parameters:
partitionAwareness-trueif jdbc thin partition awareness is enabled for this connection, iffalsethen it's disabled.
-
getUpdateBatchSize
@Nullable public @Nullable Integer getUpdateBatchSize()
Note: Batch size of 1 prevents deadlock on update where keys sequence are different in several concurrent updates.- Specified by:
getUpdateBatchSizein interfaceConnectionProperties- Returns:
- update internal bach size.
-
setUpdateBatchSize
public void setUpdateBatchSize(@Nullable @Nullable Integer updateBatchSize) throws SQLExceptionNote: Set to 1 to prevent deadlock on update where keys sequence are different in several concurrent updates.- Specified by:
setUpdateBatchSizein interfaceConnectionProperties- Parameters:
updateBatchSize- update internal bach size.- Throws:
SQLException- On error.
-
getPartitionAwarenessSqlCacheSize
public int getPartitionAwarenessSqlCacheSize()
- Specified by:
getPartitionAwarenessSqlCacheSizein interfaceConnectionProperties- Returns:
- SQL cache size that is used within partition awareness optimizations.
-
setPartitionAwarenessSqlCacheSize
public void setPartitionAwarenessSqlCacheSize(int partitionAwarenessSqlCacheSize) throws SQLExceptionSets SQL cache size that is used within partition awareness optimizations.- Specified by:
setPartitionAwarenessSqlCacheSizein interfaceConnectionProperties- Parameters:
partitionAwarenessSqlCacheSize- SQL cache size.- Throws:
SQLException- On error.
-
getPartitionAwarenessPartitionDistributionsCacheSize
public int getPartitionAwarenessPartitionDistributionsCacheSize()
- Specified by:
getPartitionAwarenessPartitionDistributionsCacheSizein interfaceConnectionProperties- Returns:
- Partition distributions cache size that is used within partition awareness optimizations.
-
setPartitionAwarenessPartitionDistributionsCacheSize
public void setPartitionAwarenessPartitionDistributionsCacheSize(int partitionAwarenessPartDistributionsCacheSize) throws SQLExceptionSets partition distributions cache size that is used within partition awareness optimizations.- Specified by:
setPartitionAwarenessPartitionDistributionsCacheSizein interfaceConnectionProperties- Parameters:
partitionAwarenessPartDistributionsCacheSize- Partition distributions cache size.- Throws:
SQLException- On error.
-
getQueryTimeout
public Integer getQueryTimeout()
Note: zero value means there is no limits.- Specified by:
getQueryTimeoutin interfaceConnectionProperties- Returns:
- Query timeout in seconds.
-
setQueryTimeout
public void setQueryTimeout(@Nullable @Nullable Integer timeout) throws SQLExceptionNote: zero value means there is no limits.- Specified by:
setQueryTimeoutin interfaceConnectionProperties- Parameters:
timeout- Query timeout in seconds.- Throws:
SQLException
-
getConnectionTimeout
public int getConnectionTimeout()
Note: zero value means there is no limits.- Specified by:
getConnectionTimeoutin interfaceConnectionProperties- Returns:
- Connection timeout in milliseconds.
-
setConnectionTimeout
public void setConnectionTimeout(@Nullable @Nullable Integer timeout) throws SQLExceptionNote: zero value means there is no limits.- Specified by:
setConnectionTimeoutin interfaceConnectionProperties- Parameters:
timeout- Connection timeout in milliseconds.- Throws:
SQLException
-
getUserAttributesFactory
public String getUserAttributesFactory()
Gets the class name of the custom implementation of the Factory<Map<String, String>>. This factory should return user attributes which can be used on server node.- Specified by:
getUserAttributesFactoryin interfaceConnectionProperties- Returns:
- Custom class name that implements Factory<Map<String, String>>.
-
setUserAttributesFactory
public void setUserAttributesFactory(String cls)
Sets the class name of the custom implementation of the Factory<Map<String, String>>. This factory should return user attributes which can be used on server node. Sent attributes can be accessed on server nodes fromGridRestRequestorClientListenerAbstractConnectionContext(depends on client type).- Specified by:
setUserAttributesFactoryin interfaceConnectionProperties- Parameters:
cls- Custom class name that implements Factory<Map<String, String>>.
-
disabledFeatures
public String disabledFeatures()
Any JDBC features could be force disabled. SeeJdbcThinFeature. The string should contain enumeration of feature names, separated by the comma.- Specified by:
disabledFeaturesin interfaceConnectionProperties- Returns:
- disabled features.
-
disabledFeatures
public void disabledFeatures(String features)
- Specified by:
disabledFeaturesin interfaceConnectionProperties- Parameters:
features- Disabled features. SeeJdbcThinFeature. The string should contain enumeration of feature names, separated by the comma.
-
isKeepBinary
public boolean isKeepBinary()
Get keep binary configuration flag.- Specified by:
isKeepBinaryin interfaceConnectionProperties- Returns:
- Keep binary configuration flag.
-
setKeepBinary
public void setKeepBinary(boolean keepBinary)
Set totrueto keep binary objects in binary form.Defaults is
false.- Specified by:
setKeepBinaryin interfaceConnectionProperties- Parameters:
keepBinary- Whether to keep binary objects in binary form.
-
getQueryEngine
public String getQueryEngine()
- Specified by:
getQueryEnginein interfaceConnectionProperties- Returns:
- SQL query engine name to use by a connection.
-
setQueryEngine
public void setQueryEngine(String qryEngine)
Sets SQL query engine for a connection.- Specified by:
setQueryEnginein interfaceConnectionProperties- Parameters:
qryEngine- SQL Query engine name.
-
getTransactionConcurrency
public TransactionConcurrency getTransactionConcurrency()
- Specified by:
getTransactionConcurrencyin interfaceConnectionProperties- Returns:
- Transaction concurrency value.
-
setTransactionConcurrency
public void setTransactionConcurrency(String transactionConcurrency)
Sets transaction concurrency.- Specified by:
setTransactionConcurrencyin interfaceConnectionProperties- Parameters:
transactionConcurrency- Transaction concurrecny.
-
getTransactionTimeout
public int getTransactionTimeout()
- Specified by:
getTransactionTimeoutin interfaceConnectionProperties- Returns:
- Transaction timeout in milliseconds.
-
setTransactionTimeout
public void setTransactionTimeout(int transactionTimeout) throws SQLExceptionSets transaction timeout in milliseconds.- Specified by:
setTransactionTimeoutin interfaceConnectionProperties- Parameters:
transactionTimeout- Transaction timeout in millicesonds.- Throws:
SQLException
-
getTransactionLabel
public String getTransactionLabel()
- Specified by:
getTransactionLabelin interfaceConnectionProperties- Returns:
- Transaction label.
-
setTransactionLabel
public void setTransactionLabel(String transactionLabel)
Sets transaction label.- Specified by:
setTransactionLabelin interfaceConnectionProperties- Parameters:
transactionLabel- Transaction label.
-
init
public void init(String url, Properties props) throws SQLException
- Parameters:
url- URL connection.props- Environment properties.- Throws:
SQLException- On error.
-
getDriverPropertyInfo
public DriverPropertyInfo[] getDriverPropertyInfo()
- Returns:
- Driver's properties info array.
-
storeToProperties
public Properties storeToProperties()
- Returns:
- Properties set contains connection parameters.
-
-