Tabnine Logo
ConnectionSourceBase.getConnection
Code IndexAdd Tabnine to your IDE (free)

How to use
getConnection
method
in
ch.qos.logback.core.db.ConnectionSourceBase

Best Java code snippets using ch.qos.logback.core.db.ConnectionSourceBase.getConnection (Showing top 8 results out of 315)

origin: camunda/camunda-bpm-platform

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
 Connection connection = null;
 try {
  connection = getConnection();
  if (connection == null) {
   addWarn("Could not get a connection");
   return;
  }
  DatabaseMetaData meta = connection.getMetaData();
  DBUtil util = new DBUtil();
  util.setContext(getContext());
  supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
  supportsBatchUpdates = util.supportsBatchUpdates(meta);
  dialectCode = DBUtil.discoverSQLDialect(meta);
  addInfo("Driver name="+meta.getDriverName());
  addInfo("Driver version="+meta.getDriverVersion());
  addInfo("supportsGetGeneratedKeys="+supportsGetGeneratedKeys);
  
 } catch (SQLException se) {
  addWarn("Could not discover the dialect to use.", se);
 } finally {
  DBHelper.closeConnection(connection);
 }
}
origin: com.alibaba.citrus.tool/antx-autoexpand

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnnectionProperties() {
 try {
  Connection connection = getConnection();
  if (connection == null) {
   addWarn("Could not get a connection");
   return;
  }
  DatabaseMetaData meta = connection.getMetaData();
  DBUtil util = new DBUtil();
  util.setContext(getContext());
  supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
  supportsBatchUpdates = util.supportsBatchUpdates(meta);
  dialectCode = DBUtil.discoverSQLDialect(meta);
  System.out.println("Driver name="+meta.getDriverName());
  System.out.println("Driver version="+meta.getDriverVersion());
  System.out.println("supportsGetGeneratedKeys="+supportsGetGeneratedKeys);
  
 } catch (SQLException se) {
  addWarn("Could not discover the dialect to use.", se);
 }
}
origin: at.bestsolution.efxclipse.eclipse/ch.qos.logback.core

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
 try {
  Connection connection = getConnection();
  if (connection == null) {
   addWarn("Could not get a connection");
   return;
  }
  DatabaseMetaData meta = connection.getMetaData();
  DBUtil util = new DBUtil();
  util.setContext(getContext());
  supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
  supportsBatchUpdates = util.supportsBatchUpdates(meta);
  dialectCode = DBUtil.discoverSQLDialect(meta);
  addInfo("Driver name="+meta.getDriverName());
  addInfo("Driver version="+meta.getDriverVersion());
  addInfo("supportsGetGeneratedKeys="+supportsGetGeneratedKeys);
  
 } catch (SQLException se) {
  addWarn("Could not discover the dialect to use.", se);
 }
}
origin: ch.qos.logback/core

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
 try {
  Connection connection = getConnection();
  if (connection == null) {
   addWarn("Could not get a connection");
   return;
  }
  DatabaseMetaData meta = connection.getMetaData();
  DBUtil util = new DBUtil();
  util.setContext(getContext());
  supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
  supportsBatchUpdates = util.supportsBatchUpdates(meta);
  dialectCode = DBUtil.discoverSQLDialect(meta);
  addInfo("Driver name="+meta.getDriverName());
  addInfo("Driver version="+meta.getDriverVersion());
  addInfo("supportsGetGeneratedKeys="+supportsGetGeneratedKeys);
  
 } catch (SQLException se) {
  addWarn("Could not discover the dialect to use.", se);
 }
}
origin: com.impetus.fabric/fabric-jdbc-driver-shaded

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
  Connection connection = null;
  try {
    connection = getConnection();
    if (connection == null) {
      addWarn("Could not get a connection");
      return;
    }
    DatabaseMetaData meta = connection.getMetaData();
    DBUtil util = new DBUtil();
    util.setContext(getContext());
    supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
    supportsBatchUpdates = util.supportsBatchUpdates(meta);
    dialectCode = DBUtil.discoverSQLDialect(meta);
    addInfo("Driver name=" + meta.getDriverName());
    addInfo("Driver version=" + meta.getDriverVersion());
    addInfo("supportsGetGeneratedKeys=" + supportsGetGeneratedKeys);
  } catch (SQLException se) {
    addWarn("Could not discover the dialect to use.", se);
  } finally {
    DBHelper.closeConnection(connection);
  }
}
origin: com.hynnet/logback-core

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
 Connection connection = null;
 try {
  connection = getConnection();
  if (connection == null) {
   addWarn("Could not get a connection");
   return;
  }
  DatabaseMetaData meta = connection.getMetaData();
  DBUtil util = new DBUtil();
  util.setContext(getContext());
  supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
  supportsBatchUpdates = util.supportsBatchUpdates(meta);
  dialectCode = DBUtil.discoverSQLDialect(meta);
  addInfo("Driver name="+meta.getDriverName());
  addInfo("Driver version="+meta.getDriverVersion());
  addInfo("supportsGetGeneratedKeys="+supportsGetGeneratedKeys);
  
 } catch (SQLException se) {
  addWarn("Could not discover the dialect to use.", se);
 } finally {
  DBHelper.closeConnection(connection);
 }
}
origin: Nextdoor/bender

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
  Connection connection = null;
  try {
    connection = getConnection();
    if (connection == null) {
      addWarn("Could not get a connection");
      return;
    }
    DatabaseMetaData meta = connection.getMetaData();
    DBUtil util = new DBUtil();
    util.setContext(getContext());
    supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
    supportsBatchUpdates = util.supportsBatchUpdates(meta);
    dialectCode = DBUtil.discoverSQLDialect(meta);
    addInfo("Driver name=" + meta.getDriverName());
    addInfo("Driver version=" + meta.getDriverVersion());
    addInfo("supportsGetGeneratedKeys=" + supportsGetGeneratedKeys);
  } catch (SQLException se) {
    addWarn("Could not discover the dialect to use.", se);
  } finally {
    DBHelper.closeConnection(connection);
  }
}
origin: io.virtdata/virtdata-lib-realer

/**
 * Learn relevant information about this connection source.
 *
 */
public void discoverConnectionProperties() {
  Connection connection = null;
  try {
    connection = getConnection();
    if (connection == null) {
      addWarn("Could not get a connection");
      return;
    }
    DatabaseMetaData meta = connection.getMetaData();
    DBUtil util = new DBUtil();
    util.setContext(getContext());
    supportsGetGeneratedKeys = util.supportsGetGeneratedKeys(meta);
    supportsBatchUpdates = util.supportsBatchUpdates(meta);
    dialectCode = DBUtil.discoverSQLDialect(meta);
    addInfo("Driver name=" + meta.getDriverName());
    addInfo("Driver version=" + meta.getDriverVersion());
    addInfo("supportsGetGeneratedKeys=" + supportsGetGeneratedKeys);
  } catch (SQLException se) {
    addWarn("Could not discover the dialect to use.", se);
  } finally {
    DBHelper.closeConnection(connection);
  }
}
ch.qos.logback.core.dbConnectionSourceBasegetConnection

Popular methods of ConnectionSourceBase

  • addWarn
  • getContext
  • start
  • addInfo

Popular in Java

  • Reactive rest calls using spring rest template
  • getApplicationContext (Context)
  • onCreateOptionsMenu (Activity)
  • scheduleAtFixedRate (Timer)
  • BufferedInputStream (java.io)
    A BufferedInputStream adds functionality to another input stream-namely, the ability to buffer the i
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Charset (java.nio.charset)
    A charset is a named mapping between Unicode characters and byte sequences. Every Charset can decode
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • TimeUnit (java.util.concurrent)
    A TimeUnit represents time durations at a given unit of granularity and provides utility methods to
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now