(halt-db!)
Stops database, if it is running.
Stops database, if it is running.
(init-db!
{:keys [port delete-after-shutdown base-dir data-dir security-disabled]
:or {port 4306
delete-after-shutdown true
base-dir (str (System/getProperty "java.io.tmpdir") "/maria-base")
data-dir (str (System/getProperty "java.io.tmpdir") "/maria-data")
security-disabled true}})
Starts a temporary MariaDB instance and returns it.
Available options to configure DB:
Starts a temporary MariaDB instance and returns it. Available options to configure DB: - port - base-dir - data-dir - security-disabled
(is-running?)
Checks if the database is currently running. returns true if running, and false if not.
Checks if the database is currently running. returns true if running, and false if not.
(with-db! f
{:keys [port delete-after-shutdown base-dir data-dir security-disabled
on-error]
:or
{port 4306
delete-after-shutdown true
base-dir (str (System/getProperty "java.io.tmpdir") "/maria-base")
data-dir (str (System/getProperty "java.io.tmpdir") "/maria-data")
security-disabled true
on-error nil}})
Starts a temporary MariaDB instance and executes the provided function f
with database being available and ensures that database shuts down properly after function f
is finished.
Available options to configure DB:
Starts a temporary MariaDB instance and executes the provided function `f` with database being available and ensures that database shuts down properly after function `f` is finished. Available options to configure DB: - port - base-dir - data-dir - security-disabled - on-error
cljdoc builds & hosts documentation for Clojure/Script libraries
Ctrl+k | Jump to recent docs |
← | Move to previous article |
→ | Move to next article |
Ctrl+/ | Jump to the search field |