Tabnine Logo
PooledConnectionFactoryConfigurationBuilder.driverClass
Code IndexAdd Tabnine to your IDE (free)

How to use
driverClass
method
in
org.infinispan.persistence.jdbc.configuration.PooledConnectionFactoryConfigurationBuilder

Best Java code snippets using org.infinispan.persistence.jdbc.configuration.PooledConnectionFactoryConfigurationBuilder.driverClass (Showing top 6 results out of 315)

origin: org.infinispan/infinispan-cachestore-jdbc

public static ConnectionFactoryConfigurationBuilder<?> configureBrokenConnectionFactory
   (AbstractJdbcStoreConfigurationBuilder<?, ?> storeBuilder) {
 return storeBuilder.connectionPool()
       .driverClass(NON_EXISTENT_DRIVER);
}
origin: org.infinispan/infinispan-tools

  private static void createConnectionConfig(StoreProperties props, JdbcStringBasedStoreConfigurationBuilder storeBuilder) {
   props.required(props.key(CONNECTION_POOL, CONNECTION_URL));
   props.required(props.key(CONNECTION_POOL, DRIVER_CLASS));

   storeBuilder.connectionPool()
      .connectionUrl(props.get(CONNECTION_POOL, CONNECTION_URL))
      .driverClass(props.get(CONNECTION_POOL, DRIVER_CLASS))
      .username(props.get(CONNECTION_POOL, USERNAME))
      .password(props.get(CONNECTION_POOL, PASSWORD))
      .create();
  }
}
origin: org.infinispan/infinispan-cachestore-jdbc

public static ConnectionFactoryConfigurationBuilder<?> configureUniqueConnectionFactory(AbstractJdbcStoreConfigurationBuilder<?, ?> store) {
 switch (dt) {
 case H2:
   return store
    .connectionPool()
      .driverClass(org.h2.Driver.class)
      .connectionUrl(String.format("jdbc:h2:mem:%s;DB_CLOSE_DELAY=-1", extractTestName() + userIndex.incrementAndGet()))
      .username("sa");
 case MYSQL:
   return store
    .simpleConnection()
      .driverClass(com.mysql.jdbc.Driver.class)
      .connectionUrl("jdbc:mysql://localhost/infinispan?user=ispn&password=ispn")
      .username("ispn")
      .password("ispn");
 default:
   throw new RuntimeException("Cannot configure connection for database type "+dt);
 }
}
origin: org.infinispan/infinispan-tools

private void parseConnectionPoolAttributes(XMLExtendedStreamReader reader,
                     PooledConnectionFactoryConfigurationBuilder<?> builder) throws XMLStreamException {
 for (int i = 0; i < reader.getAttributeCount(); i++) {
   ParseUtils.requireNoNamespaceAttribute(reader, i);
   String value = replaceProperties(reader.getAttributeValue(i));
   Attribute attribute = Attribute.forName(reader.getAttributeLocalName(i));
   switch (attribute) {
    case CONNECTION_URL: {
      builder.connectionUrl(value);
      break;
    }
    case DRIVER_CLASS: {
      builder.driverClass(value);
      break;
    }
    case PASSWORD: {
      builder.password(value);
      break;
    }
    case USERNAME: {
      builder.username(value);
      break;
    }
    default: {
      throw ParseUtils.unexpectedAttribute(reader, i);
    }
   }
 }
 ParseUtils.requireNoContent(reader);
}
origin: org.infinispan/infinispan-cachestore-jdbc

builder.driverClass(value);
break;
origin: org.infinispan/infinispan-lucene-directory

@Override
protected EmbeddedCacheManager createCacheManager() throws Exception {
 ConfigurationBuilder cb = TestCacheManagerFactory.getDefaultCacheConfiguration(false);
 cb.persistence()
    .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
    .preload(true)
    .key2StringMapper(LuceneKey2StringMapper.class)
    .table()
    .idColumnName("ID_COLUMN")
    .idColumnType("VARCHAR(255)")
    .tableNamePrefix("ISPN_JDBC")
    .dataColumnName("DATA_COLUMN")
    .dataColumnType("BLOB")
    .timestampColumnName("TIMESTAMP_COLUMN")
    .timestampColumnType("BIGINT")
    .connectionPool()
    .driverClass(org.h2.Driver.class)
    .connectionUrl("jdbc:h2:mem:infinispan;DB_CLOSE_DELAY=0")
    .username("sa");
 return TestCacheManagerFactory.createClusteredCacheManager(cb);
}
org.infinispan.persistence.jdbc.configurationPooledConnectionFactoryConfigurationBuilderdriverClass

Popular methods of PooledConnectionFactoryConfigurationBuilder

  • connectionUrl
  • username
  • password
  • create
  • fetchPersistentState
  • propertyFile
  • withProperties

Popular in Java

  • Updating database using SQL prepared statement
  • setRequestProperty (URLConnection)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getResourceAsStream (ClassLoader)
  • InputStream (java.io)
    A readable source of bytes.Most clients will use input streams that read data from the file system (
  • BitSet (java.util)
    The BitSet class implements abit array [http://en.wikipedia.org/wiki/Bit_array]. Each element is eit
  • Callable (java.util.concurrent)
    A task that returns a result and may throw an exception. Implementors define a single method with no
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.> This module, both source code and documentation, is in t
  • Top Vim 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