OmniSciDB  ab4938a6a3
com.omnisci.jdbc.OmniSciConnection Class Reference
+ Inheritance diagram for com.omnisci.jdbc.OmniSciConnection:
+ Collaboration diagram for com.omnisci.jdbc.OmniSciConnection:

Classes

class  Connection_properties
 

Public Member Functions

OmniSciConnection getAlternateConnection () throws SQLException
 
 OmniSciConnection (String url, Properties info) throws SQLException
 
Statement createStatement () throws SQLException
 
PreparedStatement prepareStatement (String sql) throws SQLException
 
CallableStatement prepareCall (String sql) throws SQLException
 
String nativeSQL (String sql) throws SQLException
 
void setAutoCommit (boolean autoCommit) throws SQLException
 
boolean getAutoCommit () throws SQLException
 
void commit () throws SQLException
 
void rollback () throws SQLException
 
void close () throws SQLException
 
boolean isClosed () throws SQLException
 
DatabaseMetaData getMetaData () throws SQLException
 
void setReadOnly (boolean readOnly) throws SQLException
 
boolean isReadOnly () throws SQLException
 
void setCatalog (String catalog) throws SQLException
 
String getCatalog () throws SQLException
 
void setTransactionIsolation (int level) throws SQLException
 
int getTransactionIsolation () throws SQLException
 
SQLWarning getWarnings () throws SQLException
 
void clearWarnings () throws SQLException
 
Statement createStatement (int resultSetType, int resultSetConcurrency) throws SQLException
 
PreparedStatement prepareStatement (String sql, int resultSetType, int resultSetConcurrency) throws SQLException
 
CallableStatement prepareCall (String sql, int resultSetType, int resultSetConcurrency) throws SQLException
 
Map< String, Class<?> > getTypeMap () throws SQLException
 
void setTypeMap (Map< String, Class<?>> map) throws SQLException
 
void setHoldability (int holdability) throws SQLException
 
int getHoldability () throws SQLException
 
Savepoint setSavepoint () throws SQLException
 
Savepoint setSavepoint (String name) throws SQLException
 
void rollback (Savepoint savepoint) throws SQLException
 
void releaseSavepoint (Savepoint savepoint) throws SQLException
 
Statement createStatement (int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException
 
PreparedStatement prepareStatement (String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException
 
CallableStatement prepareCall (String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException
 
PreparedStatement prepareStatement (String sql, int autoGeneratedKeys) throws SQLException
 
PreparedStatement prepareStatement (String sql, int[] columnIndexes) throws SQLException
 
PreparedStatement prepareStatement (String sql, String[] columnNames) throws SQLException
 
Clob createClob () throws SQLException
 
Blob createBlob () throws SQLException
 
NClob createNClob () throws SQLException
 
SQLXML createSQLXML () throws SQLException
 
boolean isValid (int timeout) throws SQLException
 
void setClientInfo (String name, String value) throws SQLClientInfoException
 
void setClientInfo (Properties properties) throws SQLClientInfoException
 
String getClientInfo (String name) throws SQLException
 
Properties getClientInfo () throws SQLException
 
Array createArrayOf (String typeName, Object[] elements) throws SQLException
 
Struct createStruct (String typeName, Object[] attributes) throws SQLException
 
void setSchema (String schema) throws SQLException
 
String getSchema () throws SQLException
 
void abort (Executor executor) throws SQLException
 
void setNetworkTimeout (Executor executor, int milliseconds) throws SQLException
 
int getNetworkTimeout () throws SQLException
 
boolean isWrapperFor (Class<?> iface) throws SQLException
 

Protected Member Functions

void closeConnection () throws SQLException
 

Protected Attributes

String session = null
 
OmniSci.Client client = null
 
String catalog
 
TTransport transport
 
SQLWarning warnings
 
String url
 
Connection_properties cP = null
 

Package Functions

public< T > T unwrap (Class< T > iface) throws SQLException
 

Package Attributes

Set< String > protocol_set
 

Static Package Attributes

static final Logger logger = LoggerFactory.getLogger(OmniSciConnection.class)
 

Private Member Functions

TProtocol manageConnection () throws java.lang.Exception
 
void setSession (Object pki_auth) throws java.lang.Exception
 

Detailed Description

Definition at line 138 of file OmniSciConnection.java.

Constructor & Destructor Documentation

◆ OmniSciConnection()

com.omnisci.jdbc.OmniSciConnection.OmniSciConnection ( String  url,
Properties  info 
) throws SQLException
inline

Definition at line 398 of file OmniSciConnection.java.

References com.omnisci.jdbc.Connection_enums.db_name, com.omnisci.jdbc.OmniSciExceptionText.getExceptionDetail(), and com.omnisci.jdbc.Connection_enums.pkiauth.

399  { // logger.debug("Entered");
400  this.url = url;
401  this.cP = new Connection_properties(info, url);
402 
403  try {
404  TProtocol protocol = manageConnection();
405  client = new OmniSci.Client(protocol);
406  setSession(this.cP.get(Connection_enums.pkiauth));
407  catalog = (String) this.cP.get(Connection_enums.db_name);
408  } catch (TTransportException ex) {
409  throw new SQLException("Thrift transport connection failed - "
410  + OmniSciExceptionText.getExceptionDetail(ex),
411  ex);
412  } catch (TOmniSciException ex) {
413  throw new SQLException("Omnisci connection failed - "
414  + OmniSciExceptionText.getExceptionDetail(ex),
415  ex);
416  } catch (TException ex) {
417  throw new SQLException(
418  "Thrift failed - " + OmniSciExceptionText.getExceptionDetail(ex), ex);
419  } catch (java.lang.Exception ex) {
420  throw new SQLException(
421  "Connection failed - " + OmniSciExceptionText.getExceptionDetail(ex), ex);
422  }
423  }
+ Here is the call graph for this function:

Member Function Documentation

◆ abort()

void com.omnisci.jdbc.OmniSciConnection.abort ( Executor  executor) throws SQLException
inline

Definition at line 847 of file OmniSciConnection.java.

847  { // logger.debug("Entered");
848  throw new UnsupportedOperationException("Not supported yet,"
849  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
850  + " class:" + new Throwable().getStackTrace()[0].getClassName()
851  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
852  }

◆ clearWarnings()

void com.omnisci.jdbc.OmniSciConnection.clearWarnings ( ) throws SQLException
inline

Definition at line 567 of file OmniSciConnection.java.

567  { // logger.debug("Entered");
568  warnings = null;
569  }

◆ close()

void com.omnisci.jdbc.OmniSciConnection.close ( ) throws SQLException
inline

Definition at line 478 of file OmniSciConnection.java.

478  { // logger.debug("Entered");
479  try {
480  logger.debug("Session at close is " + session);
481  if (session != null) {
482  client.disconnect(session);
483  }
484  closeConnection();
485  } catch (TOmniSciException ex) {
486  throw new SQLException("disconnect failed." + ex.toString());
487  } catch (TException ex) {
488  throw new SQLException("disconnect failed." + ex.toString());
489  }
490  }

◆ closeConnection()

void com.omnisci.jdbc.OmniSciConnection.closeConnection ( ) throws SQLException
inlineprotected

Definition at line 493 of file OmniSciConnection.java.

Referenced by com.omnisci.jdbc.OmniSciStatement.cancel().

493  { // logger.debug("Entered");
494  session = null;
495  transport.close();
496  }
+ Here is the caller graph for this function:

◆ commit()

void com.omnisci.jdbc.OmniSciConnection.commit ( ) throws SQLException
inline

Definition at line 465 of file OmniSciConnection.java.

465  { // logger.debug("Entered");
466  // noop
467  }

◆ createArrayOf()

Array com.omnisci.jdbc.OmniSciConnection.createArrayOf ( String  typeName,
Object []  elements 
) throws SQLException
inline

Definition at line 803 of file OmniSciConnection.java.

804  { // logger.debug("Entered");
805  throw new UnsupportedOperationException("Not supported yet,"
806  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
807  + " class:" + new Throwable().getStackTrace()[0].getClassName()
808  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
809  }

◆ createBlob()

Blob com.omnisci.jdbc.OmniSciConnection.createBlob ( ) throws SQLException
inline

Definition at line 732 of file OmniSciConnection.java.

732  { // logger.debug("Entered");
733  throw new UnsupportedOperationException("Not supported yet,"
734  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
735  + " class:" + new Throwable().getStackTrace()[0].getClassName()
736  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
737  }

◆ createClob()

Clob com.omnisci.jdbc.OmniSciConnection.createClob ( ) throws SQLException
inline

Definition at line 724 of file OmniSciConnection.java.

724  { // logger.debug("Entered");
725  throw new UnsupportedOperationException("Not supported yet,"
726  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
727  + " class:" + new Throwable().getStackTrace()[0].getClassName()
728  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
729  }

◆ createNClob()

NClob com.omnisci.jdbc.OmniSciConnection.createNClob ( ) throws SQLException
inline

Definition at line 740 of file OmniSciConnection.java.

740  { // logger.debug("Entered");
741  throw new UnsupportedOperationException("Not supported yet,"
742  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
743  + " class:" + new Throwable().getStackTrace()[0].getClassName()
744  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
745  }

◆ createSQLXML()

SQLXML com.omnisci.jdbc.OmniSciConnection.createSQLXML ( ) throws SQLException
inline

Definition at line 748 of file OmniSciConnection.java.

748  { // logger.debug("Entered");
749  throw new UnsupportedOperationException("Not supported yet,"
750  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
751  + " class:" + new Throwable().getStackTrace()[0].getClassName()
752  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
753  }

◆ createStatement() [1/3]

Statement com.omnisci.jdbc.OmniSciConnection.createStatement ( ) throws SQLException
inline

Definition at line 426 of file OmniSciConnection.java.

426  { // logger.debug("Entered");
427  return new OmniSciStatement(session, this);
428  }

◆ createStatement() [2/3]

Statement com.omnisci.jdbc.OmniSciConnection.createStatement ( int  resultSetType,
int  resultSetConcurrency 
) throws SQLException
inline

Definition at line 572 of file OmniSciConnection.java.

573  { // logger.debug("Entered");
574  return new OmniSciStatement(session, this);
575  }

◆ createStatement() [3/3]

Statement com.omnisci.jdbc.OmniSciConnection.createStatement ( int  resultSetType,
int  resultSetConcurrency,
int  resultSetHoldability 
) throws SQLException
inline

Definition at line 665 of file OmniSciConnection.java.

667  { // logger.debug("Entered");
668  throw new UnsupportedOperationException("Not supported yet,"
669  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
670  + " class:" + new Throwable().getStackTrace()[0].getClassName()
671  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
672  }

◆ createStruct()

Struct com.omnisci.jdbc.OmniSciConnection.createStruct ( String  typeName,
Object []  attributes 
) throws SQLException
inline

Definition at line 812 of file OmniSciConnection.java.

813  { // logger.debug("Entered");
814  throw new UnsupportedOperationException("Not supported yet,"
815  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
816  + " class:" + new Throwable().getStackTrace()[0].getClassName()
817  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
818  }

◆ getAlternateConnection()

OmniSciConnection com.omnisci.jdbc.OmniSciConnection.getAlternateConnection ( ) throws SQLException
inline

Definition at line 282 of file OmniSciConnection.java.

References com.omnisci.jdbc.OmniSciConnection.client, com.omnisci.jdbc.OmniSciExceptionText.getExceptionDetail(), and com.omnisci.jdbc.OmniSciConnection.manageConnection().

Referenced by com.omnisci.jdbc.OmniSciStatement.cancel().

282  {
283  // Clones the orignal java connection object, and then reconnects
284  // at the thrift layer - doesn't re-authenticate at the application
285  // level. Instead reuses the orignal connections session number.
286  logger.debug("OmniSciConnection clone");
287  OmniSciConnection omniSciConnection = null;
288  try {
289  omniSciConnection = (OmniSciConnection) super.clone();
290  } catch (CloneNotSupportedException eE) {
291  throw new SQLException(
292  "Error cloning connection [" + OmniSciExceptionText.getExceptionDetail(eE),
293  eE);
294  }
295  // Now over write the old connection.
296  try {
297  TProtocol protocol = omniSciConnection.manageConnection();
298  omniSciConnection.client = new OmniSci.Client(protocol);
299  } catch (java.lang.Exception jE) {
300  throw new SQLException("Error creating new connection "
301  + OmniSciExceptionText.getExceptionDetail(jE),
302  jE);
303  }
304  return omniSciConnection;
305  }
OmniSciConnection(String url, Properties info)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getAutoCommit()

boolean com.omnisci.jdbc.OmniSciConnection.getAutoCommit ( ) throws SQLException
inline

Definition at line 460 of file OmniSciConnection.java.

460  { // logger.debug("Entered");
461  return true;
462  }

◆ getCatalog()

String com.omnisci.jdbc.OmniSciConnection.getCatalog ( ) throws SQLException
inline

Definition at line 547 of file OmniSciConnection.java.

Referenced by com.omnisci.jdbc.OmniSciDatabaseMetaData.getTables().

547  { // logger.debug("Entered");
548  return catalog;
549  }
+ Here is the caller graph for this function:

◆ getClientInfo() [1/2]

String com.omnisci.jdbc.OmniSciConnection.getClientInfo ( String  name) throws SQLException
inline

Definition at line 786 of file OmniSciConnection.java.

787  { // logger.debug("Entered");
788  throw new UnsupportedOperationException("Not supported yet,"
789  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
790  + " class:" + new Throwable().getStackTrace()[0].getClassName()
791  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
792  }

◆ getClientInfo() [2/2]

Properties com.omnisci.jdbc.OmniSciConnection.getClientInfo ( ) throws SQLException
inline

Definition at line 795 of file OmniSciConnection.java.

795  { // logger.debug("Entered");
796  throw new UnsupportedOperationException("Not supported yet,"
797  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
798  + " class:" + new Throwable().getStackTrace()[0].getClassName()
799  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
800  }

◆ getHoldability()

int com.omnisci.jdbc.OmniSciConnection.getHoldability ( ) throws SQLException
inline

Definition at line 622 of file OmniSciConnection.java.

622  { // logger.debug("Entered");
623  throw new UnsupportedOperationException("Not supported yet,"
624  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
625  + " class:" + new Throwable().getStackTrace()[0].getClassName()
626  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
627  }

◆ getMetaData()

DatabaseMetaData com.omnisci.jdbc.OmniSciConnection.getMetaData ( ) throws SQLException
inline

Definition at line 507 of file OmniSciConnection.java.

507  { // logger.debug("Entered");
508  DatabaseMetaData mapDMetaData = new OmniSciDatabaseMetaData(this);
509 
510  return mapDMetaData;
511  }

◆ getNetworkTimeout()

int com.omnisci.jdbc.OmniSciConnection.getNetworkTimeout ( ) throws SQLException
inline

Definition at line 864 of file OmniSciConnection.java.

864  { // logger.debug("Entered");
865  throw new UnsupportedOperationException("Not supported yet,"
866  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
867  + " class:" + new Throwable().getStackTrace()[0].getClassName()
868  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
869  }

◆ getSchema()

String com.omnisci.jdbc.OmniSciConnection.getSchema ( ) throws SQLException
inline

Definition at line 839 of file OmniSciConnection.java.

839  { // logger.debug("Entered");
840  throw new UnsupportedOperationException("Not supported yet,"
841  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
842  + " class:" + new Throwable().getStackTrace()[0].getClassName()
843  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
844  }

◆ getTransactionIsolation()

int com.omnisci.jdbc.OmniSciConnection.getTransactionIsolation ( ) throws SQLException
inline

Definition at line 557 of file OmniSciConnection.java.

557  { // logger.debug("Entered");
558  return Connection.TRANSACTION_NONE;
559  }

◆ getTypeMap()

Map<String, Class<?> > com.omnisci.jdbc.OmniSciConnection.getTypeMap ( ) throws SQLException
inline

Definition at line 595 of file OmniSciConnection.java.

596  { // logger.debug("Entered");
597  throw new UnsupportedOperationException("Not supported yet,"
598  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
599  + " class:" + new Throwable().getStackTrace()[0].getClassName()
600  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
601  }

◆ getWarnings()

SQLWarning com.omnisci.jdbc.OmniSciConnection.getWarnings ( ) throws SQLException
inline

Definition at line 562 of file OmniSciConnection.java.

562  { // logger.debug("Entered");
563  return warnings;
564  }

◆ isClosed()

boolean com.omnisci.jdbc.OmniSciConnection.isClosed ( ) throws SQLException
inline

Definition at line 499 of file OmniSciConnection.java.

499  { // logger.debug("Entered");
500  if (session == null) {
501  return true;
502  }
503  return false;
504  }

◆ isReadOnly()

boolean com.omnisci.jdbc.OmniSciConnection.isReadOnly ( ) throws SQLException
inline

Definition at line 521 of file OmniSciConnection.java.

521  { // logger.debug("Entered");
522  try {
523  if (session != null) {
524  TServerStatus server_status = client.get_server_status(session);
525  return server_status.read_only;
526  }
527  } catch (TOmniSciException ex) {
528  throw new SQLException(
529  "get_server_status failed during isReadOnly check." + ex.toString());
530  } catch (TException ex) {
531  throw new SQLException(
532  "get_server_status failed during isReadOnly check." + ex.toString());
533  }
534  // never should get here
535  return true;
536  }

◆ isValid()

boolean com.omnisci.jdbc.OmniSciConnection.isValid ( int  timeout) throws SQLException
inline

Definition at line 756 of file OmniSciConnection.java.

756  { // logger.debug("Entered");
757  try {
758  client.get_server_status(session);
759  } catch (TTransportException ex) {
760  throw new SQLException("Connection failed - " + ex.toString());
761  } catch (TOmniSciException ex) {
762  throw new SQLException("Connection failed - " + ex.toString());
763  } catch (TException ex) {
764  throw new SQLException("Connection failed - " + ex.toString());
765  }
766  return true;
767  }

◆ isWrapperFor()

boolean com.omnisci.jdbc.OmniSciConnection.isWrapperFor ( Class<?>  iface) throws SQLException
inline

Definition at line 880 of file OmniSciConnection.java.

881  { // logger.debug("Entered");
882  throw new UnsupportedOperationException("Not supported yet,"
883  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
884  + " class:" + new Throwable().getStackTrace()[0].getClassName()
885  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
886  }

◆ manageConnection()

TProtocol com.omnisci.jdbc.OmniSciConnection.manageConnection ( ) throws java.lang.Exception
inlineprivate

Definition at line 307 of file OmniSciConnection.java.

References com.mapd.common.SockTransportProperties.getEncryptedClientDefaultTrustStore(), com.mapd.common.SockTransportProperties.getEncryptedClientSpecifiedTrustStore(), com.mapd.common.SockTransportProperties.getUnencryptedClient(), com.omnisci.jdbc.Connection_enums.host_name, com.omnisci.jdbc.OmniSciConnection.Connection_properties.isBinary(), com.omnisci.jdbc.OmniSciConnection.Connection_properties.isBinary_tls(), com.omnisci.jdbc.OmniSciConnection.Connection_properties.isHttpProtocol(), com.omnisci.jdbc.OmniSciConnection.Connection_properties.isHttpsProtocol(), com.omnisci.jdbc.OmniSciConnection.Connection_properties.isHttpsProtocol_insecure(), com.mapd.common.SockTransportProperties.openClientTransport(), com.mapd.common.SockTransportProperties.openHttpClientTransport(), com.mapd.common.SockTransportProperties.openHttpsClientTransport(), com.omnisci.jdbc.Connection_enums.port_num, com.omnisci.jdbc.Connection_enums.server_trust_store, and com.omnisci.jdbc.Connection_enums.server_trust_store_pwd.

Referenced by com.omnisci.jdbc.OmniSciConnection.getAlternateConnection().

307  {
308  SockTransportProperties skT = null;
309  String trust_store = null;
310  if (cP.get(Connection_enums.server_trust_store) != null
311  && !cP.get(Connection_enums.server_trust_store).toString().isEmpty()) {
312  trust_store = cP.get(Connection_enums.server_trust_store).toString();
313  }
314  String trust_store_pwd = null;
315  if (cP.get(Connection_enums.server_trust_store_pwd) != null
316  && !cP.get(Connection_enums.server_trust_store_pwd).toString().isEmpty()) {
317  trust_store_pwd = cP.get(Connection_enums.server_trust_store_pwd).toString();
318  }
319 
320  TProtocol protocol = null;
321  if (this.cP.isHttpProtocol()) {
322  // HTTP
323  skT = SockTransportProperties.getUnencryptedClient();
324 
325  transport = skT.openHttpClientTransport(
326  (String) this.cP.get(Connection_enums.host_name),
327  ((Integer) this.cP.get(Connection_enums.port_num)).intValue());
328  transport.open();
329  protocol = new TJSONProtocol(transport);
330 
331  } else if (this.cP.isBinary()) {
332  skT = SockTransportProperties.getUnencryptedClient();
333  transport =
334  skT.openClientTransport((String) this.cP.get(Connection_enums.host_name),
335  ((Integer) this.cP.get(Connection_enums.port_num)).intValue());
336  if (!transport.isOpen()) transport.open();
337  protocol = new TBinaryProtocol(transport);
338 
339  } else if (this.cP.isHttpsProtocol() || this.cP.isHttpsProtocol_insecure()) {
340  if (trust_store == null) {
341  skT = SockTransportProperties.getEncryptedClientDefaultTrustStore(
342  !this.cP.isHttpsProtocol_insecure());
343  } else {
344  skT = SockTransportProperties.getEncryptedClientSpecifiedTrustStore(
345  trust_store, trust_store_pwd, !this.cP.isHttpsProtocol_insecure());
346  }
347  transport = skT.openHttpsClientTransport(
348  (String) this.cP.get(Connection_enums.host_name),
349  ((Integer) this.cP.get(Connection_enums.port_num)).intValue());
350  transport.open();
351  protocol = new TJSONProtocol(transport);
352 
353  } else if (cP.isBinary_tls()) {
354  if (trust_store == null) {
355  skT = SockTransportProperties.getEncryptedClientDefaultTrustStore(false);
356  } else {
357  skT = SockTransportProperties.getEncryptedClientSpecifiedTrustStore(
358  trust_store, trust_store_pwd, false);
359  }
360  transport =
361  skT.openClientTransport((String) this.cP.get(Connection_enums.host_name),
362  ((Integer) this.cP.get(Connection_enums.port_num)).intValue());
363 
364  if (!transport.isOpen()) transport.open();
365  protocol = new TBinaryProtocol(transport);
366  } else {
367  throw new RuntimeException("Invalid protocol supplied");
368  }
369  return protocol;
370  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ nativeSQL()

String com.omnisci.jdbc.OmniSciConnection.nativeSQL ( String  sql) throws SQLException
inline

Definition at line 446 of file OmniSciConnection.java.

446  { // logger.debug("Entered");
447  throw new UnsupportedOperationException("Not supported yet,"
448  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
449  + " class:" + new Throwable().getStackTrace()[0].getClassName()
450  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
451  }

◆ prepareCall() [1/3]

CallableStatement com.omnisci.jdbc.OmniSciConnection.prepareCall ( String  sql) throws SQLException
inline

Definition at line 437 of file OmniSciConnection.java.

438  { // logger.debug("Entered");
439  throw new UnsupportedOperationException("Not supported yet,"
440  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
441  + " class:" + new Throwable().getStackTrace()[0].getClassName()
442  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
443  }

◆ prepareCall() [2/3]

CallableStatement com.omnisci.jdbc.OmniSciConnection.prepareCall ( String  sql,
int  resultSetType,
int  resultSetConcurrency 
) throws SQLException
inline

Definition at line 585 of file OmniSciConnection.java.

587  { // logger.debug("Entered");
588  throw new UnsupportedOperationException("Not supported yet,"
589  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
590  + " class:" + new Throwable().getStackTrace()[0].getClassName()
591  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
592  }

◆ prepareCall() [3/3]

CallableStatement com.omnisci.jdbc.OmniSciConnection.prepareCall ( String  sql,
int  resultSetType,
int  resultSetConcurrency,
int  resultSetHoldability 
) throws SQLException
inline

Definition at line 686 of file OmniSciConnection.java.

689  { // logger.debug("Entered");
690  throw new UnsupportedOperationException("Not supported yet,"
691  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
692  + " class:" + new Throwable().getStackTrace()[0].getClassName()
693  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
694  }

◆ prepareStatement() [1/6]

PreparedStatement com.omnisci.jdbc.OmniSciConnection.prepareStatement ( String  sql) throws SQLException
inline

Definition at line 431 of file OmniSciConnection.java.

432  { // logger.debug("Entered");
433  return new OmniSciPreparedStatement(sql, session, client);
434  }

◆ prepareStatement() [2/6]

PreparedStatement com.omnisci.jdbc.OmniSciConnection.prepareStatement ( String  sql,
int  resultSetType,
int  resultSetConcurrency 
) throws SQLException
inline

Definition at line 578 of file OmniSciConnection.java.

580  { // logger.debug("Entered");
581  return new OmniSciPreparedStatement(sql, session, client);
582  }

◆ prepareStatement() [3/6]

PreparedStatement com.omnisci.jdbc.OmniSciConnection.prepareStatement ( String  sql,
int  resultSetType,
int  resultSetConcurrency,
int  resultSetHoldability 
) throws SQLException
inline

Definition at line 675 of file OmniSciConnection.java.

678  { // logger.debug("Entered");
679  throw new UnsupportedOperationException("Not supported yet,"
680  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
681  + " class:" + new Throwable().getStackTrace()[0].getClassName()
682  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
683  }

◆ prepareStatement() [4/6]

PreparedStatement com.omnisci.jdbc.OmniSciConnection.prepareStatement ( String  sql,
int  autoGeneratedKeys 
) throws SQLException
inline

Definition at line 697 of file OmniSciConnection.java.

698  { // logger.debug("Entered");
699  throw new UnsupportedOperationException("Not supported yet,"
700  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
701  + " class:" + new Throwable().getStackTrace()[0].getClassName()
702  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
703  }

◆ prepareStatement() [5/6]

PreparedStatement com.omnisci.jdbc.OmniSciConnection.prepareStatement ( String  sql,
int []  columnIndexes 
) throws SQLException
inline

Definition at line 706 of file OmniSciConnection.java.

707  { // logger.debug("Entered");
708  throw new UnsupportedOperationException("Not supported yet,"
709  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
710  + " class:" + new Throwable().getStackTrace()[0].getClassName()
711  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
712  }

◆ prepareStatement() [6/6]

PreparedStatement com.omnisci.jdbc.OmniSciConnection.prepareStatement ( String  sql,
String []  columnNames 
) throws SQLException
inline

Definition at line 715 of file OmniSciConnection.java.

716  { // logger.debug("Entered");
717  throw new UnsupportedOperationException("Not supported yet,"
718  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
719  + " class:" + new Throwable().getStackTrace()[0].getClassName()
720  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
721  }

◆ releaseSavepoint()

void com.omnisci.jdbc.OmniSciConnection.releaseSavepoint ( Savepoint  savepoint) throws SQLException
inline

Definition at line 656 of file OmniSciConnection.java.

657  { // logger.debug("Entered");
658  throw new UnsupportedOperationException("Not supported yet,"
659  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
660  + " class:" + new Throwable().getStackTrace()[0].getClassName()
661  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
662  }

◆ rollback() [1/2]

void com.omnisci.jdbc.OmniSciConnection.rollback ( ) throws SQLException
inline

Definition at line 470 of file OmniSciConnection.java.

470  { // logger.debug("Entered");
471  throw new UnsupportedOperationException("Not supported yet,"
472  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
473  + " class:" + new Throwable().getStackTrace()[0].getClassName()
474  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
475  }

◆ rollback() [2/2]

void com.omnisci.jdbc.OmniSciConnection.rollback ( Savepoint  savepoint) throws SQLException
inline

Definition at line 647 of file OmniSciConnection.java.

648  { // logger.debug("Entered");
649  throw new UnsupportedOperationException("Not supported yet,"
650  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
651  + " class:" + new Throwable().getStackTrace()[0].getClassName()
652  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
653  }

◆ setAutoCommit()

void com.omnisci.jdbc.OmniSciConnection.setAutoCommit ( boolean  autoCommit) throws SQLException
inline

Definition at line 454 of file OmniSciConnection.java.

455  { // logger.debug("Entered");
456  // we always autocommit per statement
457  }

◆ setCatalog()

void com.omnisci.jdbc.OmniSciConnection.setCatalog ( String  catalog) throws SQLException
inline

Definition at line 539 of file OmniSciConnection.java.

539  { // logger.debug("Entered");
540  throw new UnsupportedOperationException("Not supported yet,"
541  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
542  + " class:" + new Throwable().getStackTrace()[0].getClassName()
543  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
544  }

◆ setClientInfo() [1/2]

void com.omnisci.jdbc.OmniSciConnection.setClientInfo ( String  name,
String  value 
) throws SQLClientInfoException
inline

Definition at line 770 of file OmniSciConnection.java.

770  {
771  throw new UnsupportedOperationException("Not supported yet,"
772  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
773  + " class:" + new Throwable().getStackTrace()[0].getClassName()
774  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
775  }

◆ setClientInfo() [2/2]

void com.omnisci.jdbc.OmniSciConnection.setClientInfo ( Properties  properties) throws SQLClientInfoException
inline

Definition at line 778 of file OmniSciConnection.java.

778  {
779  throw new UnsupportedOperationException("Not supported yet,"
780  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
781  + " class:" + new Throwable().getStackTrace()[0].getClassName()
782  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
783  }

◆ setHoldability()

void com.omnisci.jdbc.OmniSciConnection.setHoldability ( int  holdability) throws SQLException
inline

Definition at line 613 of file OmniSciConnection.java.

614  { // logger.debug("Entered");
615  throw new UnsupportedOperationException("Not supported yet,"
616  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
617  + " class:" + new Throwable().getStackTrace()[0].getClassName()
618  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
619  }

◆ setNetworkTimeout()

void com.omnisci.jdbc.OmniSciConnection.setNetworkTimeout ( Executor  executor,
int  milliseconds 
) throws SQLException
inline

Definition at line 855 of file OmniSciConnection.java.

856  { // logger.debug("Entered");
857  throw new UnsupportedOperationException("Not supported yet,"
858  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
859  + " class:" + new Throwable().getStackTrace()[0].getClassName()
860  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
861  }

◆ setReadOnly()

void com.omnisci.jdbc.OmniSciConnection.setReadOnly ( boolean  readOnly) throws SQLException
inline

Definition at line 514 of file OmniSciConnection.java.

515  { // logger.debug("Entered");
516  // TODO MAT we can't push the readonly upstream currently
517  // but we could make JDBC obey this command
518  }

◆ setSavepoint() [1/2]

Savepoint com.omnisci.jdbc.OmniSciConnection.setSavepoint ( ) throws SQLException
inline

Definition at line 630 of file OmniSciConnection.java.

630  { // logger.debug("Entered");
631  throw new UnsupportedOperationException("Not supported yet,"
632  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
633  + " class:" + new Throwable().getStackTrace()[0].getClassName()
634  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
635  }

◆ setSavepoint() [2/2]

Savepoint com.omnisci.jdbc.OmniSciConnection.setSavepoint ( String  name) throws SQLException
inline

Definition at line 638 of file OmniSciConnection.java.

639  { // logger.debug("Entered");
640  throw new UnsupportedOperationException("Not supported yet,"
641  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
642  + " class:" + new Throwable().getStackTrace()[0].getClassName()
643  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
644  }

◆ setSchema()

void com.omnisci.jdbc.OmniSciConnection.setSchema ( String  schema) throws SQLException
inline

Definition at line 821 of file OmniSciConnection.java.

References com.omnisci.jdbc.Connection_enums.db_name.

821  { // logger.debug("Entered");
822  // Setting setSchema to be a NOOP allows integration with third party products
823  // that require a successful call to setSchema to work.
824  Object db_name = this.cP.get(Connection_enums.db_name);
825  if (db_name == null) {
826  throw new RuntimeException("db name not set, "
827  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
828  + " class:" + new Throwable().getStackTrace()[0].getClassName()
829  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
830  }
831  if (!schema.equals(db_name.toString())) {
832  logger.warn("Connected to schema [" + schema + "] differs from db name [" + db_name
833  + "].");
834  }
835  return;
836  }

◆ setSession()

void com.omnisci.jdbc.OmniSciConnection.setSession ( Object  pki_auth) throws java.lang.Exception
inlineprivate

Definition at line 372 of file OmniSciConnection.java.

References com.omnisci.jdbc.Connection_enums.db_name, com.omnisci.jdbc.KeyLoader.getDetails_pkcs12(), com.omnisci.jdbc.Connection_enums.sslcert, com.omnisci.jdbc.Connection_enums.sslkey_password, com.omnisci.jdbc.Connection_enums.user, and com.omnisci.jdbc.Connection_enums.user_passwd.

372  {
373  KeyLoader.S_struct s_struct = null;
374  // If pki aut then stuff public cert into password.
375  if (pki_auth != null && pki_auth.toString().equalsIgnoreCase("true")) {
376  s_struct = KeyLoader.getDetails_pkcs12(
377  this.cP.get(Connection_enums.sslcert).toString(),
378  this.cP.get(Connection_enums.sslkey_password).toString());
379  this.cP.put(Connection_enums.user_passwd, s_struct.cert);
380  }
381 
382  // Get the seesion for all connectioms
383  session = client.connect((String) this.cP.get(Connection_enums.user),
384  (String) this.cP.get(Connection_enums.user_passwd),
385  (String) this.cP.get(Connection_enums.db_name));
386 
387  // if pki auth the session will be encoded.
388  if (pki_auth != null && pki_auth.toString().equalsIgnoreCase("true")) {
389  Cipher cipher = Cipher.getInstance(s_struct.key.getAlgorithm());
390  cipher.init(Cipher.DECRYPT_MODE, s_struct.key);
391  // session is encrypted and encoded in b64
392  byte[] decodedBytes = Base64.getDecoder().decode(session);
393  byte[] decoded_bytes = cipher.doFinal(decodedBytes);
394  session = new String(decoded_bytes, "UTF-8");
395  }
396  }
+ Here is the call graph for this function:

◆ setTransactionIsolation()

void com.omnisci.jdbc.OmniSciConnection.setTransactionIsolation ( int  level) throws SQLException
inline

Definition at line 552 of file OmniSciConnection.java.

553  { // logger.debug("Entered");
554  }

◆ setTypeMap()

void com.omnisci.jdbc.OmniSciConnection.setTypeMap ( Map< String, Class<?>>  map) throws SQLException
inline

Definition at line 604 of file OmniSciConnection.java.

605  { // logger.debug("Entered");
606  throw new UnsupportedOperationException("Not supported yet,"
607  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
608  + " class:" + new Throwable().getStackTrace()[0].getClassName()
609  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
610  }

◆ unwrap()

public<T> T com.omnisci.jdbc.OmniSciConnection.unwrap ( Class< T >  iface) throws SQLException
inlinepackage

Definition at line 872 of file OmniSciConnection.java.

872  { // logger.debug("Entered");
873  throw new UnsupportedOperationException("Not supported yet,"
874  + " line:" + new Throwable().getStackTrace()[0].getLineNumber()
875  + " class:" + new Throwable().getStackTrace()[0].getClassName()
876  + " method:" + new Throwable().getStackTrace()[0].getMethodName());
877  }

Member Data Documentation

◆ catalog

String com.omnisci.jdbc.OmniSciConnection.catalog
protected

Definition at line 276 of file OmniSciConnection.java.

◆ client

◆ cP

Connection_properties com.omnisci.jdbc.OmniSciConnection.cP = null
protected

◆ logger

final Logger com.omnisci.jdbc.OmniSciConnection.logger = LoggerFactory.getLogger(OmniSciConnection.class)
staticpackage

◆ protocol_set

Set<String> com.omnisci.jdbc.OmniSciConnection.protocol_set
package
Initial value:
= new HashSet<String>(
Arrays.asList("binary", "binary_tls", "http", "https", "https_insecure"))

Definition at line 141 of file OmniSciConnection.java.

◆ session

◆ transport

TTransport com.omnisci.jdbc.OmniSciConnection.transport
protected

Definition at line 277 of file OmniSciConnection.java.

◆ url

String com.omnisci.jdbc.OmniSciConnection.url
protected

◆ warnings

SQLWarning com.omnisci.jdbc.OmniSciConnection.warnings
protected

Definition at line 278 of file OmniSciConnection.java.


The documentation for this class was generated from the following file: