Package oracle.jdbc.datasource

## Interface OracleDataSource

All Superinterfaces:
  `CommonDataSource`, `DataSource`, `OracleCommonDataSource`, `Wrapper`

All Known Subinterfaces:
  `OracleConnectionPoolDataSource`, `OracleDataSource`, `OracleXADataSource`

All Known Implementing Classes:
  `OracleConnectionPoolDataSource`, `OracleConnectionPoolDataSource`, `OracleConnectionPoolDataSourceImpl`, `OracleDataSource`, `OracleDataSource`, `OracleDataSourceImpl`, `OracleOCIConnectionPool`, `OracleXADataSource`, `OracleXADataSource`, `OracleXADataSourceImpl`

    public interface OracleDataSource
    extends DataSource, OracleCommonDataSource

This interface defines the Oracle extensions to the standard JDBC interface `DataSource`.

Since:
  12.2

### Method Summary

All Methods Static Methods Instance Methods Abstract Methods
`OracleConnectionBuilder` `createConnectionBuilder()` Create a new `OracleConnectionBuilder` instance
`static void` `setExecutorService​(ExecutorService threadPool)` Sets the thread pool for general use inside the Oracle JDBC driver.

### Methods inherited from interface javax.sql.CommonDataSource

`getParentLogger`

### Methods inherited from interface javax.sql.DataSource

`getConnection, getConnection, getLoginTimeout, getLogWriter, setLoginTimeout, setLogWriter`

### Methods inherited from interface oracle.jdbc.datasource.OracleCommonDataSource

`createShardingKeyBuilder, getConnectionProperties, getConnectionProperty, getDatabaseName, getDataSourceName, getDescription, getExplicitCachingEnabled, getImplicitCachingEnabled, getMaxStatements, getNetworkProtocol, getPortNumber, getRoleName, getServerName, getURL, getUser, setConnectionProperties, setConnectionProperty, setDatabaseName, setDataSourceName, setDescription, setExplicitCachingEnabled, setHostnameResolver, setImplicitCachingEnabled, setMaxStatements, setNetworkProtocol, setPassword, setPortNumber, setRoleName, setServerName, setSingleShardTransactionSupport, setSSLContext, setTokenSupplier, setURL, setUser`

### Methods inherited from interface java.sql.Wrapper

`isWrapperFor, unwrap`

### Method Detail

#### createConnectionBuilder

    OracleConnectionBuilder createConnectionBuilder()
                                             throws SQLException

Create a new `OracleConnectionBuilder` instance

Specified by:
  `createConnectionBuilder` in interface `DataSource`
Returns:
  The `OracleConnectionBuilder` instance that was created
Throws:
  `SQLException` - if an error occurs while creating the builder

#### setExecutorService

    static void setExecutorService​(ExecutorService threadPool)
                            throws SQLException

Sets the thread pool for general use inside the Oracle JDBC driver. The thread pool set is used across all data source instances. Setting this has global effect. The existing thread pool will be shut down immediately. The thread pool set should in general be a `ThreadPoolExecutor`. Do not use `ForkJoinPool`.

Throws:
  `SQLException` - if an error occurs while setting the thread pool.