Class JDBCPool

  • All Implemented Interfaces:
    RxDelegate

    public class JDBCPool
    extends Pool
    implements RxDelegate
    JDBCPool is the interface that allows using the Sql Client API with plain JDBC.

    NOTE: This class has been automatically generated from the original non RX-ified interface using Vert.x codegen.

    • Field Detail

      • DEFAULT_DATA_SOURCE_PROVIDER

        public static final Supplier<DataSourceProvider> DEFAULT_DATA_SOURCE_PROVIDER
        The default data source provider for this pool, loaded from JVM system properties with the key. The value can be one of:
        • C3P0:
        • Hikari:
        • Agroal:
        When there is no JVM wide defined provider or the value is incorrect, is returned.
      • GENERATED_KEYS

        public static final PropertyKind<Row> GENERATED_KEYS
        The property to be used to retrieve the generated keys
      • OUTPUT

        public static final PropertyKind<Boolean> OUTPUT
        The property to be used to retrieve the output of the callable statement
    • Constructor Detail

      • JDBCPool

        public JDBCPool​(JDBCPool delegate)
      • JDBCPool

        public JDBCPool​(Object delegate)
    • Method Detail

      • equals

        public boolean equals​(Object o)
        Overrides:
        equals in class Pool
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Pool
      • pool

        @Deprecated
        public static JDBCPool pool​(Vertx vertx,
                                    JsonObject config)
        Deprecated.
        Create a JDBC pool which maintains its own data source.
        Parameters:
        vertx - the Vert.x instance
        config - the options to configure the client using the same format as JDBCClient
        Returns:
        the client
      • pool

        public static JDBCPool pool​(Vertx vertx,
                                    JDBCConnectOptions connectOptions,
                                    PoolOptions poolOptions,
                                    DataSourceProvider provider)
        Create a JDBC pool which maintains its own data source, with the specified provider
        Parameters:
        vertx - the Vert.x instance
        connectOptions - the options to configure the connection
        poolOptions - the connection pool options
        provider - the data source provider
        Returns:
        the client
      • pool

        public static JDBCPool pool​(Vertx vertx,
                                    DataSourceProvider dataSourceProvider)
        Create a JDBC pool which maintains its own data source.
        Parameters:
        vertx - the Vert.x instance
        dataSourceProvider - the options to configure the client using the same format as JDBCClient
        Returns:
        the client
      • pool

        public static JDBCPool pool​(Vertx vertx,
                                    DataSource dataSource)
        Create a JDBC pool using a pre-initialized data source.
        Parameters:
        vertx - the Vert.x instance
        dataSource - a pre-initialized data source
        Returns:
        the client
      • pool

        @Deprecated
        public static JDBCPool pool​(Vertx vertx,
                                    DataSource dataSource,
                                    JsonObject config)
        Deprecated.
        Create a JDBC pool using a pre-initialized data source. The config expects that at least the following properties are set:
        • url - the connection string
        • user - the connection user name
        • database - the database name
        • maxPoolSize - the max allowed number of connections in the pool
        Parameters:
        vertx - the Vert.x instance
        dataSource - a pre-initialized data source
        config - the pool configuration
        Returns:
        the client