Package io.deephaven.jdbc
Class DeephavenConnection
java.lang.Object
io.deephaven.jdbc.DeephavenConnection
- All Implemented Interfaces:
AutoCloseable
,Connection
,Wrapper
public class DeephavenConnection extends Object implements Connection
An implementation of JDBC Connection that authenticates if needed, creates and attaches to a Deephaven worker.
The worker should have the same lifetime as the Connection, and will be used to execute any Statement or
PreparedStatements created through this connection. This is not thread-safe.
-
Field Summary
Fields inherited from interface java.sql.Connection
TRANSACTION_NONE, TRANSACTION_READ_COMMITTED, TRANSACTION_READ_UNCOMMITTED, TRANSACTION_REPEATABLE_READ, TRANSACTION_SERIALIZABLE
-
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.sql.Connection
beginRequest, endRequest, setShardingKey, setShardingKey, setShardingKeyIfValid, setShardingKeyIfValid
-
Method Details
-
createStatement
- Specified by:
createStatement
in interfaceConnection
-
prepareStatement
- Specified by:
prepareStatement
in interfaceConnection
-
prepareCall
- Specified by:
prepareCall
in interfaceConnection
- Throws:
SQLException
-
nativeSQL
- Specified by:
nativeSQL
in interfaceConnection
-
setAutoCommit
public void setAutoCommit(boolean autoCommit)- Specified by:
setAutoCommit
in interfaceConnection
-
getAutoCommit
public boolean getAutoCommit()- Specified by:
getAutoCommit
in interfaceConnection
-
commit
- Specified by:
commit
in interfaceConnection
- Throws:
SQLException
-
rollback
- Specified by:
rollback
in interfaceConnection
- Throws:
SQLException
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceConnection
-
isClosed
public boolean isClosed()- Specified by:
isClosed
in interfaceConnection
-
getMetaData
- Specified by:
getMetaData
in interfaceConnection
-
setReadOnly
- Specified by:
setReadOnly
in interfaceConnection
- Throws:
SQLException
-
isReadOnly
public boolean isReadOnly()- Specified by:
isReadOnly
in interfaceConnection
-
setCatalog
- Specified by:
setCatalog
in interfaceConnection
-
getCatalog
- Specified by:
getCatalog
in interfaceConnection
-
setTransactionIsolation
- Specified by:
setTransactionIsolation
in interfaceConnection
- Throws:
SQLException
-
getTransactionIsolation
public int getTransactionIsolation()- Specified by:
getTransactionIsolation
in interfaceConnection
-
getWarnings
- Specified by:
getWarnings
in interfaceConnection
-
clearWarnings
public void clearWarnings()- Specified by:
clearWarnings
in interfaceConnection
-
createStatement
- Specified by:
createStatement
in interfaceConnection
- Throws:
SQLException
-
prepareStatement
public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency) throws SQLException- Specified by:
prepareStatement
in interfaceConnection
- Throws:
SQLException
-
prepareCall
public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency) throws SQLException- Specified by:
prepareCall
in interfaceConnection
- Throws:
SQLException
-
getTypeMap
- Specified by:
getTypeMap
in interfaceConnection
-
setTypeMap
- Specified by:
setTypeMap
in interfaceConnection
-
setHoldability
- Specified by:
setHoldability
in interfaceConnection
- Throws:
SQLException
-
getHoldability
public int getHoldability()- Specified by:
getHoldability
in interfaceConnection
-
setSavepoint
- Specified by:
setSavepoint
in interfaceConnection
- Throws:
SQLException
-
setSavepoint
- Specified by:
setSavepoint
in interfaceConnection
- Throws:
SQLException
-
rollback
- Specified by:
rollback
in interfaceConnection
- Throws:
SQLException
-
releaseSavepoint
- Specified by:
releaseSavepoint
in interfaceConnection
- Throws:
SQLException
-
createStatement
public Statement createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException- Specified by:
createStatement
in interfaceConnection
- Throws:
SQLException
-
prepareStatement
public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException- Specified by:
prepareStatement
in interfaceConnection
- Throws:
SQLException
-
prepareCall
public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException- Specified by:
prepareCall
in interfaceConnection
- Throws:
SQLException
-
prepareStatement
- Specified by:
prepareStatement
in interfaceConnection
- Throws:
SQLException
-
prepareStatement
- Specified by:
prepareStatement
in interfaceConnection
- Throws:
SQLException
-
prepareStatement
- Specified by:
prepareStatement
in interfaceConnection
- Throws:
SQLException
-
createClob
- Specified by:
createClob
in interfaceConnection
- Throws:
SQLException
-
createBlob
- Specified by:
createBlob
in interfaceConnection
- Throws:
SQLException
-
createNClob
- Specified by:
createNClob
in interfaceConnection
- Throws:
SQLException
-
createSQLXML
- Specified by:
createSQLXML
in interfaceConnection
- Throws:
SQLException
-
isValid
- Specified by:
isValid
in interfaceConnection
- Throws:
SQLException
-
setClientInfo
- Specified by:
setClientInfo
in interfaceConnection
-
setClientInfo
- Specified by:
setClientInfo
in interfaceConnection
-
getClientInfo
- Specified by:
getClientInfo
in interfaceConnection
- Throws:
SQLException
-
getClientInfo
- Specified by:
getClientInfo
in interfaceConnection
- Throws:
SQLException
-
createArrayOf
- Specified by:
createArrayOf
in interfaceConnection
- Throws:
SQLException
-
createStruct
- Specified by:
createStruct
in interfaceConnection
- Throws:
SQLException
-
setSchema
- Specified by:
setSchema
in interfaceConnection
-
getSchema
- Specified by:
getSchema
in interfaceConnection
-
abort
- Specified by:
abort
in interfaceConnection
-
setNetworkTimeout
- Specified by:
setNetworkTimeout
in interfaceConnection
- Throws:
SQLException
-
getNetworkTimeout
public int getNetworkTimeout()- Specified by:
getNetworkTimeout
in interfaceConnection
-
unwrap
-
isWrapperFor
- Specified by:
isWrapperFor
in interfaceWrapper
-