shard-crystal-db/src/db
Brian J. Cardiff f13846b133
Refactor connection factory (#181)
* Start moving out URI from ConnectionContext

Create connections with an initial context. Database will set itself as context after connection has been created

* Migrate to simpler/decoupled factory in driver

This allows more freedom on how the connection is created. It will no longer need to have an explicit reference to the connection URI

* Introduce DB::Connection::Options

Move prepared_statements out from ConnectionContext

* Delegate options parsing to driver

DRY parsing connection options for database

* Introduce DB::Pool::Options

* Rename Driver#connection_pool_options to pool_options

* Drop driver getter from database

* Drop uri getter from database

* Add public Database#initialize method

* Drop :nodoc: Database#initialize

* Pass spec helper explicitly (to access methods within each spec)

* Update docs

* Update src/db/pool.cr

Co-authored-by: Beta Ziliani <beta@manas.tech>

* Use ConnectionBuilder instead of procs

* Fix inferred type when there is a single concrete connection type

* Update src/db/driver.cr

Co-authored-by: Beta Ziliani <beta@manas.tech>

---------

Co-authored-by: Beta Ziliani <beta@manas.tech>
2023-06-22 22:03:08 -03:00
..
begin_transaction.cr Close a transaction when `return`ing from within its block (#167) 2022-10-27 18:35:57 +02:00
connection.cr Refactor connection factory (#181) 2023-06-22 22:03:08 -03:00
connection_builder.cr Refactor connection factory (#181) 2023-06-22 22:03:08 -03:00
connection_context.cr Refactor connection factory (#181) 2023-06-22 22:03:08 -03:00
database.cr Refactor connection factory (#181) 2023-06-22 22:03:08 -03:00
disposable.cr fix #1. avoid marking as closed if do_close raise exception 2016-06-24 10:54:30 -03:00
driver.cr Refactor connection factory (#181) 2023-06-22 22:03:08 -03:00
enumerable_concat.cr Add logging for executing queries (#134) 2020-09-25 14:49:50 -03:00
error.cr Improve DB::MappingException usage (#129) 2021-10-12 20:51:53 -03:00
mapping.cr Improve DB::MappingException usage (#129) 2021-10-12 20:51:53 -03:00
pool.cr Refactor connection factory (#181) 2023-06-22 22:03:08 -03:00
pool_prepared_statement.cr Fix mt issues (#178) 2023-04-24 12:26:25 +02:00
pool_statement.cr Statement#exec and #query require named argument for array values (#110) 2019-09-20 17:23:09 -03:00
pool_unprepared_statement.cr Add type argument to QueryMethods module (#108) 2019-08-02 11:54:52 -03:00
query_methods.cr Use DB::NoResultsError on QueryMethods (#125) 2020-04-06 18:36:37 -03:00
result_set.cr Allow the use of enums (#168) 2022-10-26 16:06:14 +02:00
serializable.cr Improve DB::MappingException usage (#129) 2021-10-12 20:51:53 -03:00
session_methods.cr Add type argument to QueryMethods module (#108) 2019-08-02 11:54:52 -03:00
statement.cr Add logging for executing queries (#134) 2020-09-25 14:49:50 -03:00
string_key_cache.cr Fix mt issues (#178) 2023-04-24 12:26:25 +02:00
transaction.cr Add type argument to QueryMethods module (#108) 2019-08-02 11:54:52 -03:00
version.cr Release 0.11.0 (#157) 2022-01-27 10:56:35 -03:00