Low-level logic for creating connection pools for a JDBC-based database. Used by both application DB and connected data warehouse DBs.
The aim here is to completely encapsulate the connection pool library we use -- that way we can swap it out if we want to at some point without having to touch any other files. (TODO - this is currently true of everything except for the options, which are c3p0-specific -- consider abstracting those as well?)
Low-level logic for creating connection pools for a JDBC-based database. Used by both application DB and connected data warehouse DBs. The aim here is to completely encapsulate the connection pool library we use -- that way we can swap it out if we want to at some point without having to touch any other files. (TODO - this is currently true of everything except for the options, which are c3p0-specific -- consider abstracting those as well?)
(connection-pool-spec spec)
(connection-pool-spec spec pool-properties-map)
(connection-pool-spec driver spec pool-properties-map)
Create a new connection pool for a JDBC spec
and return a spec for it. Optionally pass a map of connection pool
properties -- see https://www.mchange.com/projects/c3p0/#configuration_properties for a description of valid options
and their default values.
Create a new connection pool for a JDBC `spec` and return a spec for it. Optionally pass a map of connection pool properties -- see https://www.mchange.com/projects/c3p0/#configuration_properties for a description of valid options and their default values.
(destroy-connection-pool! spec-or-data-source)
Immediately release all resources held by a connection pool.
Immediately release all resources held by a connection pool.
(map->properties m)
Create a Properties
object from a JDBC connection spec map. Properties objects are maps of String -> String, so all
keys and values are converted to Strings appropriately.
Create a `Properties` object from a JDBC connection spec map. Properties objects are maps of String -> String, so all keys and values are converted to Strings appropriately.
(pooled-data-source spec)
(pooled-data-source spec pool-properties-map)
(pooled-data-source driver spec pool-properties-map)
Create a new pooled DataSource from a clojure.java.jdbc
spec.
Create a new pooled DataSource from a `clojure.java.jdbc` spec.
(pooled-data-source-from-url url)
(pooled-data-source-from-url url pool-properties-map)
(pooled-data-source-from-url driver url pool-properties-map)
Create a new pooled DataSource from a JDBC URL string.
Create a new pooled DataSource from a JDBC URL string.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close