Commit graph

116 commits

Author SHA1 Message Date
Brian J. Cardiff
c58cea290c
Release 0.21.0, Update to crystal-db ~> 0.13 (#94)
* Update crystal-db ~> 0.13.0

* Bump version to 0.21.0
2023-12-12 22:15:47 -03:00
Brian J. Cardiff
1f2a1cd3cb
Release 0.20.0 (#92) 2023-06-23 16:29:58 -03:00
Brian J. Cardiff
c08fc2befc
Update to crystal-db 0.12.0 (refactor connection factory) (#91)
* Refactor connection builder

* Update for ConnectionBuilder

* Update to crystal-db ~> 0.12.0

* run crystal tool format
2023-06-23 15:36:08 -03:00
Brian J. Cardiff
79615e6c85
Reset before close (#90) 2023-04-24 12:53:56 -03:00
Luis Lavena
84857724c1
Automatically set PRAGMAs using connection query params (#85)
* Automatically set PRAGMAs using connection query params

Introduce the flexibility to adjust certain PRAGMAs of the SQLite3
connection without having to hardcode those in your codebase (and wait
for compilation).

This allows applications to use `DATABASE_URL` to dynamically fine tune
their SQLite3 configuration.

The change complements `#setup_connection` that offers, via code, the
option to perform queries on setup of each connection.

Only a few PRAGMAs necessary to allow more performant concurrent reads
and reduce write locking.

These pragmas are detected and combined in a single SQL string to reduce
to 1 the number of calls to `sqlite3_exec` C function.

There is no validation of supplied values as SQLite3 automatically
ignores incorrect values for these pragmas.

Closes #84

References:
- https://www.sqlite.org/pragma.html

* Simplify PRAGMA mapping and detection

No longer prefix PRAGMAS with `_`, so the mapping between the real
SQLite3 pragmas and the usage in the URI is more direct.

Use macros instead of case to detect pragmas from URI params and return
those as NamedTuple.

* Update README.md

---------

Co-authored-by: Brian J. Cardiff <bcardiff@gmail.com>
2023-02-18 17:06:09 -03:00
Brian J. Cardiff
d15a8da05c
Release 0.19.0 (#79) 2022-01-28 15:33:18 -03:00
Brian J. Cardiff
a9baaec310
Migrate CI to GitHub Actions (#78) 2022-01-28 15:14:33 -03:00
Brian J. Cardiff
2849fe15c8
Update to crystal-db ~> 0.11.0 (#77) 2022-01-27 11:09:27 -03:00
Ryan Westlund
985bfa2d7c
Fix timestamp reading issue (#68) 2021-02-28 14:18:08 -03:00
Brian J. Cardiff
367c11031d
Release 0.18.0 (#67) 2021-01-26 16:11:20 -03:00
Ryan Westlund
55b8399d7e
Enable REGEXP by connecting Crystal's stdlib Regex (#62) 2020-11-11 15:00:40 -03:00
Brian J. Cardiff
4abea0d326
Release 0.17.0 (#60) 2020-09-30 16:01:48 -03:00
Brian J. Cardiff
d440f55b2f
CI: Add CircleCI using manastech/crystal@1.0 (#59) 2020-09-30 11:56:46 -03:00
Brian J. Cardiff
8586182fd8
Update crystal-db ~> 0.10.0 and Crystal 0.35.0 for logging support (#58)
* Update crystal-db for logging support

* Update sample

* Update to crystal-db ~> 0.10.0
2020-09-30 11:34:25 -03:00
Brian J. Cardiff
5f6055f4bd
Release 0.16.0 (#56) 2020-04-06 21:12:05 -03:00
Brian J. Cardiff
ce0ca1c884
Update to crystal-db ~> 0.9.0 (#55) 2020-04-06 20:23:00 -03:00
Brian J. Cardiff
d9f916a598
Update README.md for dynamic args (#53) 2020-01-14 10:29:58 -03:00
Brian J. Cardiff
aed9acb225
Release 0.15.0 (#51) 2019-12-11 17:59:42 -03:00
Brian J. Cardiff
751bd5de97
Update to crystal-db ~> 0.8.0 (#50) 2019-12-11 17:48:03 -03:00
Brian J. Cardiff
746c0a5f5e
Release 0.14.0 (#45) 2019-09-23 10:31:01 -03:00
Brian J. Cardiff
013292d834
Update to crystal-db ~> 0.7.0 (#44) 2019-09-23 10:18:45 -03:00
Brian J. Cardiff
25a9dd8b0f Release 0.13.0 2019-08-02 12:35:23 -03:00
Brian J. Cardiff
611eec5aed
Merge pull request #43 from crystal-lang/crystal/v0.30.0
Upgrade to Crystal v0.30.0
2019-08-02 12:25:30 -03:00
Brian J. Cardiff
c363665bba Update to crystal-db ~> 0.6.0 2019-08-02 12:21:40 -03:00
Brian J. Cardiff
5303492839 Upgrade to Crystal v0.30.0 2019-07-30 19:17:12 -03:00
Brian J. Cardiff
058c78f837 Annotate return types of abstract methods 2019-07-29 10:25:46 -03:00
Brian J. Cardiff
54089ef97d
Release 0.12.0 (#41) 2019-06-07 10:23:14 -03:00
Brian J. Cardiff
57cef3acd3
Merge pull request #40 from crystal-lang/crystal/0.29.0
Upgrade to Crystal 0.29.0
2019-06-06 15:58:08 -03:00
Brian J. Cardiff
4b4441bb37 Code cleanup due to Crystal >= 0.28.0 2019-06-06 12:36:16 -03:00
Brian J. Cardiff
2bfda2aa13 Fix Time.new deprecation warning
Enforce Crystal 0.28.0 or later
2019-06-04 17:54:24 -03:00
Brian J. Cardiff
ba1763b3a3
Release 0.11.0 (#39) 2019-04-19 02:03:29 -03:00
Brian J. Cardiff
c621a9b701
Upgrade to Crystal 0.28.0 (#38) 2019-04-18 15:58:02 -03:00
Tom Richards
a95182be08 Add error codes to LibSQLite3::Code (#36) 2018-10-05 11:53:19 -03:00
Brian J. Cardiff
2152441749 Bump version 0.10.0. Release notes. 2018-06-18 10:31:19 +02:00
Brian J. Cardiff
c1f214d695
Upgrade time usage for crystal 0.25.0 (#34) 2018-06-18 10:26:32 +02:00
Brian J. Cardiff
13916070e0 Bump version. Release notes. 2017-12-31 00:22:31 -03:00
Brian J. Cardiff
1f56a27704 Update to crystal-db ~> 0.5.0 2017-12-31 00:18:12 -03:00
Brian J. Cardiff
ae84010c28 Use text instead of string as sqlite type
Ref: crystal-lang/crystal-db#71
2017-11-13 10:59:59 -03:00
Brian J. Cardiff
adf64daa08 Bump version. Release notes.
Add SQLite3::VERSION constant
2017-11-07 23:49:41 -03:00
Ryan Breen
790d0ded8b Bytes argument properly bind blob, not text (#28) 2017-09-19 16:48:05 -03:00
Tom Richards
e6d5ad33c3 Multi-step exec support (#27) 2017-09-14 15:51:25 -03:00
Brian J. Cardiff
c850ec4b72 Update travis 2017-05-29 15:32:31 -03:00
Benoist
616af3ba1d better closing checks (#23) 2017-05-29 15:20:32 -03:00
Brian J. Cardiff
5eb85a98c6 Update to crystal-db ~> 0.4.1
Replace driver_spec for db/spec.
Fix read(T?) for T = Int32, Flaot32, Time, Bool..
Fixes #19
2017-04-10 14:09:22 -03:00
Brian J. Cardiff
b66dd5c337 bump version 0.8.2 2017-03-21 15:54:03 -03:00
Brian J. Cardiff
b43a12fc92 Add spec for DB.connect
Update to crystal-db ~> 0.4.0
2017-03-21 15:46:57 -03:00
Hinrik Örn Sigurðsson
bbed6256a6 Make SQLite3::Connection#dump copy all DB pages (#16)
An issue with bindings caused less than total pages to be copied.
2017-01-17 16:57:27 -03:00
Brian J. Cardiff
c3ee15db6a update .gitignore 2016-12-26 10:46:08 -03:00
Brian J. Cardiff
cc4ab2d06f bump version 0.8.1 2016-12-15 15:22:41 -03:00
Brian J. Cardiff
bda4b8e184 update to crystal-db ~> 0.3.1 2016-12-15 14:49:39 -03:00